display error message.. [message #262770] |
Tue, 28 August 2007 04:47 |
brintha
Messages: 28 Registered: August 2007
|
Junior Member |
|
|
hi all,
can anybody help me in displaying error message when the passed parameter doesnot match any value in the database.
I tried out the following code...
begin
temp varchar2(20);
SELECT LOCATION_XID INTO temp FROM LOCATION WHERE
LOCATION_XID=:P_PROVID;
IF temp IS NULL THEN
SRW.MESSAGE(2,'INVALID PROVIDER ID');
raise SRW.PROGRAM_ABORT;
END IF;
end;
:P_PROVID is the parameter that is passed. I checked this against the location id. I added the code in after parameter form report triggers. I got an error.
REP - 1401:'afterpform'
Fatal PL/SQL error occured
ORA-01403 no data found.
Please help me in where to write that code in validation triggers or afterpform ? and is this code correct?
thanks & regards,
brintha.r
|
|
|
|
|