need helps on error message [message #85963] |
Tue, 17 August 2004 21:50 |
Dhalan
Messages: 15 Registered: August 2004
|
Junior Member |
|
|
SELECT nama INTO :DATANG.NAME FROM PEKERJA WHERE ICNO= :DATANG.ICNO;
i use above statement to view record exist from when-validate-item. what if the records does not exist and how to display the error message and can u give example with my statement above. thanks may god bless you
|
|
|
Re: need helps on error message [message #85966 is a reply to message #85963] |
Tue, 17 August 2004 23:16 |
Himanshu
Messages: 457 Registered: December 2001
|
Senior Member |
|
|
Hi,
Use the following code:
Begin
SELECT name INTO :DATANG.NAME FROM PEKERJA
WHERE ICNO= :DATANG.ICNO;
excpetion
when No_data_found then
Message('No data available.',No_acknowledge);
raise_form_trigger_failure;
when others then
Message(Error while selecting data.',No_acknowledge);
raise_form_trigger_failure;
End;
HTH
regards
Himanshu
|
|
|
|