I have a database that is a little inverted. For every project row, there are columns for different Engineers involved. (architect engineer, construction engineer, mechanical engineer). I need to get a list of projects that are assigned to one person. So to do that, I need to write a query that will search for their job title in the columns based on a drop down list. I am using Dynamic Linq and I have written a query like this
Dim db As New DesignConstructionDataContext
Dim query = db.all_drawings.Where("@0 = Kevin O'lausen", "ddlJobTitle.value").Select("ProjectNumber").toList
But when I run this, the eror I get says "=" is not compatible with string values. and when I try using "is" instead, it says it needs to be a boolean value. I am very green to this Dynamic linq thing, any help would be great!
Methiks you a bit confused with linq.
So, as i understand
ddlJobTitle.value
, and"Kevin O'lausen"
So you need change your query like