I want perform join which is based on subquery result
e.g.
from p in ProductSet
join i in itemassociationsSet on p.ProductId equals i.childproductitemid.Id
where i.parentproductitemid.Id == new Guid(ProductSet.Where(w => w.ProductNumber == strList)
.Select(s => s.ProductId)
.FirstOrDefault().ToString()) &&
i.eet_EffectiveDate.Value <= DateTime.Now &&
i.eet_ExpiryDate.Value >= DateTime.Now &&
p.ProductTypeCode.Value == typecode &&
(p.ProductNumber.Contains(tryValue) || p.Name.Contains(tryValue) &&
p.companyvalue.Value == '111212' &&
p.StateCode.Value == '0' &&
p.IsStockItem == IsStockItem
select new Products
{
ProductNumber = p.ProductNumber,
Name = p.Name
}
How can i do this?
*This post is locked for comments