c# - Proper use of StartWith and Contains in Entity Framework -


I remove the prefixes from the Linq links in the StoreName field I want> query

> Query 2

  var objRetailer = From store in context. Join ReetailerStoredtls to join the reference Retailer Contact Dtls at stores. ReetailerID is equal to ret.RetailerID stores on context.RetailerRegDates. ReetailerID equals retreg.RetailerRegDateId where (stores.IsDeleted == zero) stores.Is deleted == incorrect) & amp; Amp; (Stores ready Date Price Year == iYear || stores.ModifiedDate.Value.Year == iYear) & amp; Amp; Retreg.IsAprproved == The right orderbay stores. Select store name new {store.StoreID, store = stores} Store name, area = stores Storecity, zip = stores. Store Zip, Selling Card = (Stores. Ritter ID.Value)? True: False) StoreWithoutPrefix = stores.StoreName.StartsWith (& lt; Question 1 & gt; One of the prefixes in stores. Store name: & lt; stores.StoreName without prefix & gt;};  

Unfortunately we do not take string parameters as a result of .startwith () which Query1 , if I go with . does will not check whether it starts with it or not, just check whether the string exists or not. What should you do to complete this task?

Thank you.

You can use IndexOf , but you probably have problems with the sensitivity of the matter, so add a parameter option to select .gnomecase

< / Html>

Comments

Popular posts from this blog

ios - How do I use CFArrayRef in Swift? -

eclipse plugin - Run java code error: Workspace is closed -

c - Error on building source code in VC 6 -