Posted By

housecor on 10/27/10


Tagged


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite

Tyster


Filtering EntityCollections in LINQ


 / Published in: C#
 

Uses lambda and any operator to filter list.

  1. from c in context.Contacts
  2. where c.Addresses.Any(a => a.CountryRegion == "UK")
  3. select c;

Report this snippet  

You need to login to post a comment.