Embedded SQL WHENEVER NOT FOUND problem
From: Al Parker <al_at_cvgis.prime.com>
Date: Thu, 30 Jul 1992 13:32:15 GMT
Message-ID: <1992Jul30.133215.7885_at_cvgis.prime.com>
Date: Thu, 30 Jul 1992 13:32:15 GMT
Message-ID: <1992Jul30.133215.7885_at_cvgis.prime.com>
Greetings,
I am finding that in certain usage of the Pro*C precompiler with
'mode=ansi13' and the following code:
EXEC SQL WHENEVER NOT FOUND GOTO :c_statement1;
EXEC SQL WHENEVER SQLERROR GOTO :c_statement2;
...
EXEC SQL EXECUTE IMMEDIATE :sql_statement;
...
the Pro*C precompiler does not generate a check for the NOT FOUND
condition after the EXECUTE IMMEDIATE. (It does correctly generate
the check for the SQLERROR condition.)
The work-around is to perform the check explicitly:
if( sqlca.sqlcode == 100 ) goto c_statement1;
but it would be nice if the WHENEVER worked as documented.
Has anyone else encountered this problem ?
-- ------------------------------------------------------------------------------- Al Parker, P.Eng, Sr Software Engineer - Computervision GIS al_at_cvgis.prime.com (416)508-8020(x881) These opinions are my own and not those of my compnay.Received on Thu Jul 30 1992 - 15:32:15 CEST