select p.id,p.RetailPrice,p.minqty,p.UnitPrice, p.productID,p.productname,p.category,p.categoryID,p.description,p.img1,p.Currency,p.sellername,p.sellerID,p.currency,CP.productName as cpName,CP.productDescription as cpDesc from tProduct p left join tCatelogProduct as CP on CP.productID=P.ID where P.id in(select CPs.productID from tCatelogProduct CPs inner join tProduct P on CPs.productID=P.ID where CPs.catelogID=? ) and P.status=? and CP.catelogID=? and (P.feature<>'Private' or P.feature is null) and (cp.deleted is null or cp.deleted = 0)3138