Database SQL Operation: PlanItemApprovalCheck.countByUsernameForModify
Description: | Count entries that match this one based on userName, estimatedCost, statusCode, planItemID and which do not match the provided unique ID. Essentially this is checking for duplicates of an entry that is about to be modified. |
Sterotype: | ns |
SELECT
COUNT (*)
INTO
:recordCount
FROM
PlanItemApprovalCheck
WHERE planItemApprovalCheckID <> :planItemApprovalCheckID
AND planItemID = :planItemID
AND estimatedCost = :estimatedCost
AND statusCode = :statusCode
AND userName = :userName
|