Query3 SELECT a.product_id, a.mrepc_no, b.name, b.contact_person, b.company_no, b.office_telephone, office_fax, b.email, b.website, e.powdered, e.powder_free, c.state, c.flag, d.type, d.bimg FROM company_product_exp_upd a, company_details b, state c, business_type d, company_product e, igcat_item_upd f WHERE a.mrepc_no = b.mrepc_no and b.mrepc_no = e.mrepc_no AND (b.not_active IS NULL OR b.not_active = 0) AND b.state_id = c.state_id and e.business_type = d.type_id group by a.mrepc_no order by b.name failed