Pro*C NULLs and OCI handling therof.
Date: Thu, 24 Mar 1994 15:16:22 -0800
Message-ID: <eberts-240394151623_at_seberts.uoregon.edu>
On the DEC ALPHA, using Oracle 7.0 and the Pro*C compiler 1.5, I encounter
the
following problem, simplified as follows (i ran into it it a more realistic
application, but this describes it without any extra crap);
I've created a simple table, called TEST, with two columns, col1 (int) and col2 (char(3)). It is populated with four rows as follows;
COL1 COL2
---- ----
1 REM 2 <NULL>
<NULL> REM
<NULL> <NULL>
Then I wrote a simple Pro*C program that does nothing more than define a
cursor
to fetch the four rows. I *specifically* specify MODE=ORACLE when
precompiling,
although it is supposed to be the default.
On our standard VAX-6000, the nulls are returned by either not modifying
the
ints, or setting the .len portion of VARCHARS to 0. On the AXP,
the sqlca.sqlcode is set to -1405, instead of remaining at 0, as it does on
the 6000.
It *explicitly* states that this should not happen when MODE = ORACLE, only when MODE=[ANSI | ANSI14] and indicator variables are not used.
Why does this happen, in spite of the what the ORACLE manual states, and
more
importantly, how can we correct it?
Please respond via email. If it's in the manual somewhere, i'd even be happy with just a page reference, because three of us are stumped.
AdTHANKSvance
-- "party people in the house it's a love thang." -tom tom club sonny hays-eberts eberts_at_donald.uoregon.eduReceived on Fri Mar 25 1994 - 00:16:22 CET