Re: Esql/c problem Error -242
Posted in 1998
In article <1998040521451700.RAA13973@ladder03.news.aol.com>,
kponn@aol.com (KPonn) wrote:
>
> Hello everyone,
Hi Keith,
>
> I have a running ESQL/C program that suddenly started crashing at the same
> place in a report that it generates. SQLCODE = -242 and ISAM = -106.( After
> doing some selects and inserts etc..., this program generates a report.) I
> looked into the decriptions of these messages, I did not understand what
"run
> either bcheck or secheck on files" means.
bcheck or secheck are actually reference to the *check programs of Informix
which report and optionally, repair the tables, indices etc. The programs are
bcheck for C-ISAM, secheck for Informix SE, tbcheck for Informix OnLine v5
and oncheck for Informix OnLine v7.
>
> Can someone explain to me what's going on here.Thanks in advance for your
help.
-242 Could not open database table table-name.
-106 ISAM error: non-exclusive access.
If you go by the first finderr message (not by explanation) then you would
find that the program is not able to access a table. The program logic seems
to be asking for exclusive access to table. The second finderr statement and
explanation clarify that.
So, just before report generation or in the start of report generation, your
program seems to be either creating or dropping an index ( Is there a temp
table involved ????). The creation or deletion of index requires that the
Informix engine have exclusive access to it, which in this case is being
denied. Most probably this would be due to the fact that either your program
is still reading from this table or some other program is accessing this
table.
If indeed there is a creation of index involved then I think you should move
that statement right on the top of the program. Otherwise, there is little
else that I can cotribute without having a look at source :-(
>
> Keith
> Keith Ponnapalli
HTH,
Ravi...
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/ Now offering spam-free web-based newsreading