Again raising the question from the link. Case is Private and Payment is also Private. Payment has lookup relationship with the Case.
I have developed code which create share object for Case and Payment object.
How to combine below two query ? Is that possible to combine ?
SELECT CaseAccessLevel,CaseId,Id,IsDeleted,LastModifiedById,LastModifiedDate,RowCause,UserOrGroupId FROM CaseShare where CaseId = 'YYYY'
SELECT AccessLevel,Id,IsDeleted,LastModifiedById,LastModifiedDate,ParentId,RowCause,UserOrGroupId FROM Payment__Share where ParentId = 'XXXX'