void load3(long id_pro)
{
var data3 = from p in db.Product_details
join c in db.LoaiSps
on p.id_loai equals c.id_Loai
where p.id_loai == (from d in db.Product_details
where d.id_product_detail == id_pro
select d.id_loai)
select p;
if (data3 != null && data3.Count() > 0)
{
product3 = data3.ToList();
}
}
I tried looking at a post from someone who had the same problem as me, adding First() or Single() but it still doesn’t seem to work.