Re: SQLCA.SQLCODE = NOTFOUND, STATUS = 0 ?
Posted in 1995
> sqlca.sqlcode records the status from the last SQL statement executed.
> status records the status from the last statement executed.
> The result is that if you have the following
> select ....> let a = b
> at this point
> status will = 0
> sqlca.sqlcode will = notfound
> For this reason if you want to trap SQL errors you should always use
> sqlca.sqlcode not status as it is too easy for programmers to slip in a
> line by
> mistake.
We assumed that this would be the problem. Unfortunately it wasnt.
There are no lines in the way. Status is just not getting set to sqlcode
at all. Sadly we can recreate this at will.
As Bash says Informix reported this as a known bug with 'early' versions
of 4gl. I would not have classed 4.12 as EARLY personally (as far as I
know 4.13 is the latest release for AIXv3.2.5r5). Support were unwilling
to give any help on what the necessary 'later' version might be. The guy
was of the opinion that 'you ought to upgrade to the latest version
anyway'. Further questions only resulted in noncomital noises. I was left
with the impression that i) he just wanted to get me off the line and
close the incident, and ii) he wasnt sure what the scope of the problem
or the solution was.