c# - Unable to create a constant value of type 'Closure type' -


here linq entity query , i'm getting error

"unable create constant value of type 'closure type'. primitive types ('such int32, string, , guid') supported in context. "

does 1 know how fix or workaround.

ps. i'm using linq entity not linq sql

list<int> listint list<int> listinttwo    return (from oa in _entity.tableone           join cc in _entity.tabletwo on oa.tablesix.columnone equals cc.tablesix.columnone           join os in _entity.tablethree on oa.tablethree.columntwo equals os.columntwo           join cs in _entity.tabletwotatus on cc.tabletwotatus.columnthree equals cs.columnthree           join app in _entity.tablefour on cc.tablefour.columnfour equals app.columnfour           join cl in _entity.tablefive on app.tablefive.columnfive equals cl.columnfive           listint.any(x =>x == cc.tabletwotatus.columnthree)           && listinttwo.any(x => x == os.columntwo) && cc.tablesix.columnone == columnone            select new tablefive {columnfive = cl.columnfive, companyname = cl.companyname}).tolist(); 

try changing calls any(...) contains(...)

where listint.contains(cc.tabletwotatus.columnthree) && listinttwo.contains(os.columntwo) && ... 

i'm pretty sure it's having problems referencing joined entity lambda expressions (acting closures).


Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -