You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
frompinpswherep.OrderDetails.Contains(ods.OrderByDescending(o =>o.OrderID).ThenBy(o =>o.ProductID).FirstOrDefault(orderDetail =>orderDetail.Quantity==1))select p
this can be translated to:
frompinpswherep.OrderDetails.Select(x =>x.Id).Contains(ods.OrderByDescending(o =>o.OrderID).ThenBy(o =>o.ProductID).FirstOrDefault(orderDetail =>orderDetail.Quantity==1).Id)select p
but in case of composite keys we need to be more creative, e.g.
frompinpswherep.orderDetails.Join(ods.OrderByDescending(o =>o.OrderID).ThenBy(o =>o.ProductID).Where(orderDetail =>orderDetail.Quantity==1).Take(1),
p =>{p.Key1,p.Key2}, od =>{od.Key1,od.Key2}).Any()
The text was updated successfully, but these errors were encountered:
example query:
this can be translated to:
but in case of composite keys we need to be more creative, e.g.
The text was updated successfully, but these errors were encountered: