Use delegate for Projection in Linq to SQL
- by Redeemed1
I have code something like this in an IRepository implementation in Linq to Sql:
var newlist = from h in list where h.StringProp1 == "1"
select new MyBusinessBO{
firstProp = h.StringProp1,
secondProp = h.StringProp2
};
The projection into MyBusinessBO…