c# - The type of one of the expressions in the join clause is incorrect -
this question has reply here:
the type of 1 of expressions in bring together clause wrong in entity framework 2 answerspublic dynamic ogretimuyesigetir2(int enstitukodu, int anabilimdalikodu) { var liste = (from p in en.ogretimuyeleri bring together j in en.anabilimdallari on new { p.enstitukodu, p.anabilimdalikodu } equals new { enstitukodu = j.enstitukodu, anabilimdalikodu = anabilimdalikodu } select new { p.enstitukodu, p.anabilimdalikodu, adı = p.adi, soyadı = p.soyadi, anabilimdaliadi = j.anabilimdaliadi }).where(p => p.enstitukodu == enstitukodu && p.anabilimdalikodu == anabilimdalikodu).tolist(); homecoming liste; } error:
the type of 1 of expressions in bring together clause incorrect. type inference failed in phone call 'join'.
help me?
if alter code in equals new next one
equals new { enstitukodu = enstitukodu, anabilimdalikodu = anabilimdalikodu } it work.
c# sql linq linq-to-sql
No comments:
Post a Comment