Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> how to get sqlstate & sqlca when mode=oracle with pro*c

how to get sqlstate & sqlca when mode=oracle with pro*c

From: Michael Reppisch <spam_at_reppisch.de>
Date: Fri, 25 Jun 2004 10:32:10 +0200
Message-ID: <2k2683F16d10tU1@uni-berlin.de>


Hi Ng,

is there any way to obtain a sqlstate when precompiling with mode=oracle? I have defined the sqlca and need it!
the doc's are a bit confusing what will happen when i declare a char SQLSTATE[6]; in the declare section.

Targeted db-versions are 8 & 9

currently i'm doing this:
....
EXEC SQL INCLUDE SQLCA;
EXEC SQL INCLUDE SQLDA;
EXEC SQL WHENEVER NOT FOUND CONTINUE;
EXEC SQL WHENEVER SQLERROR CONTINUE;
EXEC SQL BEGIN DECLARE SECTION;
  char szDBDatabase[25];
  char szDBUser[17];
  char szDBPwd[17];
EXEC SQL END DECLARE SECTION; Regards,
  Michael

--
  sig comming soon :-)
Received on Fri Jun 25 2004 - 03:32:10 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US