Databases Reference
In-Depth Information
3.
You should now see the Create Validation wizard. In the first page of the
wizard, choose the Item Level Validation item (see Figure 3-2).
Figure 3-2. Selecting the type of validation
4.
In the next page of the wizard, select the PATIENTDISCHARGE: 1.
P1_PATIENTSOCIALSECURITYNO (Patientsocialsecurityno) item as the item
to be validated.
5.
In the next page, choose the PL/SQL validation method, and next the Function
Returning Boolean PL/SQL validation type.
6.
Use the default values in the next (Sequence and Name) step. Proceed to the
next (Validation) step and enter the PL/SQL validation code shown in Listing
3-4.
Listing 3-4. PL/SQL Validation Code
DECLARE
CT INTEGER;
BEGIN
SELECT COUNT(*) INTO CT FROM PAYMENTHISTORY WHERE
SOCIALSECURITYNO = :P1_PATIENTSOCIALSECURITYNO;
 
Search WWH ::




Custom Search