This question is locked. New answers and comments are not allowed.
Hi,
Suppose I have this example table.
[SampleTable]
Id : PK, uniqueidentifier
Text: varchar(3000)
I've got a search method that accepts a list of key words as a parameter. What I'd like to do is select any records from SampleTable where the Text column contains any of the key words. For example:
public IQueryable<SampleTable> Search(List<string> keywords)
{
return = from s in ObjectScope.Extent<SampleTable>()
where keywords.Any(k => s.Text.Any(t => t.Contains(k)))
select s;
}
I'd like to see if I can accomplish this using your LINQ support. Any suggestions on how to get it done? Thanks!