'Contains()' workaround using Linq to Entities?

前端 未结 10 2066
清酒与你
清酒与你 2020-11-22 14:01

I\'m trying to create a query which uses a list of ids in the where clause, using the Silverlight ADO.Net Data Services client api (and therefore Linq To Entities). Does any

10条回答
  •  醉梦人生
    2020-11-22 14:51

    I'm not sure about Silverligth, but in linq to objects i always use any() for these queries.

    var q = from t in svc.OpenTranaction
            where txnIds.Any(t.OpenTransactionId)
            select t;
    

提交回复
热议问题