I have a metadata class with some custom properties for easier data access. One problem that I have run across though, is that when I try to use this property in LINQ statements I get this error.
The specified type member 'CrewCodesStr' is not supported in LINQ to Entities.
I know why I get it, I'm wondering if there is another way to do this to allow the property to be used in LINQ statements.
Here is the property:
public string CrewCodesStr
{
get { return string.Join(", ", CrewCodesList); }
}
Here is an example query that it fails on.
query = query.Where(wo => searchCriteria.crewCode.Contains(wo.CrewCodesStr));