Case Insensitive String Search and Entity Framework

entity-framework linq

Question

A string property called Description is a part of an Entity Framework entity I have.
It is easy to search for all entities when the Description includes a certain text by typing:

var res = from u ctx.Users where u.Description.contains(str) select u;

Imagine, however, that I wish to implement case-insensitive search.

1
8
9/14/2011 11:04:15 AM

Accepted Answer

If you useLinq to enties The sql server does the search; hence, whether or not the search is case sensitive relies on server settings.

12
9/14/2011 11:19:49 AM


Related Questions





Related

Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow
Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow