SELECT
affectedRelatedReferenceID,
caseID,
relatedReferenceID,
relatedReferenceType,
relatedReferenceStatus,
createdBy,
createdOn,
lastUpdatedBy,
lastUpdatedOn,
versionNo
INTO
:affectedRelatedReferenceID,
:caseID,
:relatedReferenceID,
:relatedReferenceType,
:relatedReferenceStatus,
:createdBy,
:createdOn,
:lastUpdatedBy,
:lastUpdatedOn,
:versionNo
FROM AFFECTEDRELATEDREFERENCE WHERE
AFFECTEDRELATEDREFERENCE.caseID = :caseID AND AFFECTEDRELATEDREFERENCE.relatedReferenceType = :relatedReferenceType AND
(AFFECTEDRELATEDREFERENCE.relatedReferenceStatus = :relatedReferenceStatus1 OR AFFECTEDRELATEDREFERENCE.relatedReferenceStatus = :relatedReferenceStatus2)
|