c# - Parent-Child Filter with QueryBuilder -


suppose have 3 table: table employee, employmenthistory, , languages. 1 employee can have many language , employment history.

employee

id  name    email 1   aaa aaa@gmail.com 2   bbb bbb@gmail.com 3   ccc ccc@gmail.com 

employment history

id  employeeid   company         position 1   1            devon energy    aaa 2   2            emric           bbb 3   3            capcom          ccc 

language

id  employeeid  language    level 1   1           english     expert 2   2           dutch       expert 3   3           franch      expert 

how apply filter using objectquery querybuilder ? example: want filter employee devon company. should employee "aaa".

var emp = translate(context.employees.include("employmenthistories"));  public objectquery<t> translate<t>(objectquery<t> objectquery) {       objectquery.where("it.employmenthistories.company = 'devon energy'"); // employmenthistories.company not found. how can filter through included property } 

note: i'm using querybuilder advanced filtering.

best regards,

brian

after 1 day of excruciating pain, i've found solution. used dynamic linq provided microsoft dynamic linq solve problem


Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -