Database SQL Operation: ConcernRoleAlternateID.searchForDuplicate
Description: | method that checks for duplicate alternateID types for concernRole |
Sterotype: | nsmulti |
SELECT
concernRoleID,
concernRoleAlternateID,
typeCode,
statusCode,
startDate,
endDate
INTO
:concernRoleID,
:concernRoleAlternateID,
:typeCode,
:statusCode,
:startDate,
:endDate
FROM
ConcernRoleAlternateID
WHERE concernRoleID = :concernRoleID
AND concernRoleAlternateID <> :concernRoleAlternateID
AND typeCode = :typeCode
AND statusCode = :statusCode
AND
(
(
endDate >= :startDate
OR endDate IS NULL
)
AND
(
startDate <= :endDate
OR :endDate IS NULL
)
)
|