Re: Exception Handling
Posted in 1998
Praveen
This is the DBINFO function again. The number of rows processed by any
DML statement (SELECT, INSERT, UPDATE and DELETE) are returned in
sqlca.sqlerrd2. So right after you do a select in your SP, you can get
the number of rows returned, like so:
SELECT <colname, ...> FROM <tabname, ...> WHERE <condition>;
LET nRowsReturned = DBINFO('sqlca.sqlerrd2');
BTW, the last serial value is found in sqlca.sqlerrd1. My apologies
for saying this was sqlca.sqlerrd2 few days ago in another post.
HTH
Sujit Pal
______________________________ Reply Separator _________________________________
Subject: Exception Handling
Author: "PRAVEEN MOHANAN" <praveen_mohanan@hotmail.com> at Internet
Date: 4/30/98 11:23 AM
Hi...Users....
Env. Informix OWS 7.20. What exception is raised where
there r no rows found after a select stmt. I am trying to write a
procedure & wanted to trap this exception. Is there any way to find ,
except
select count(*) from ..... where....
if the count < 1 then
.....
end if
regards,
Praveen
______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com