select rp.ownerId, rp.ownerType, rp.requestId from tbl_TPM_RequestPartners rp with (nolock) inner join tbl_OPR_ClientOperators opr with (nolock) on opr.operatorId = rp.partnerId and opr.oprCompanyType in ( 'G','C' ) and opr.ownerId = rp.ownerId and opr.fsltablecode= rp.ownerType inner join tbl_TPM_Requests r with (nolock) on r.requestId = rp.requestId and r.ownerId = rp.ownerId and r.ownerType = rp.ownerType where rp.primaryPartner = 'Y' and rp.partnerType = 'OPR' and r.status = 'APPROVED' order by rp.ownerId