Unable to create a constant value. Only primitive types

后端 未结 2 1739
误落风尘
误落风尘 2021-02-08 11:35
dbEntities db = new dbEntities();
foreach (ttCategory c in db.ttCategories)
{
    var tags=(from t in db.ttproduktes where t.ttCategories.Contains(c) select t.ttTags);
          


        
2条回答
  •  生来不讨喜
    2021-02-08 11:59

    var tags = (from t in db.ttproduktes
                where t.ttCategories.Any(q => q.Id == c.Id)
                select t.ttTags);
    

提交回复
热议问题