0
HI這裏是我的LINQ到SQL代碼返回產品名稱的列表,從表Product..But我也想從表sale..Please幫助返回多個coloumns
var result = (from p in db.Products
where
(
from s in db.SaleDetails
join se in db.Sales
on s.SaleId equals se.Id
where
(
from s2 in db.Sales
where s2.CustomerId == customerId
select s2.Id
).Contains(s.SaleId)
select s.ProductId
).Contains(p.Id)
select p.Name
).ToList();
選擇SellDateTime coloumn從兩個不同勢表