OCI gripes

From: Konrad Schwarz <schwarz_at_mips.complang.tuwien.ac.at>
Date: 23 Feb 1994 22:39:38 GMT
Message-ID: <2kglva$rra_at_email.tuwien.ac.at>


The description of the oexn() OCI call for v6 Oracle says, ``You can continue to process the rest of the array even after a failure on one of the array elements as long as a rollback did not occur (obtained from the *flags1* field in the cursor data area).''

The bit to test for this is not documented in chapter 2 of the manual, in fact, all bits in the flags1 element are accounted for, if only marked as ``unused.'' Could someone please clarify this?

What actually happens if you use oexn() (with iters - rowoff > 1) on a cursor bound to a query? Are there any semantics for this?

Although I can commit and rollback using explicit OCI calls, no call for savepoints is available. In the sql manual (v6), these sql statements are classified as dml, however, these statements probably won't need to have placeholders bound, as do the conventional insert/delete/update. Can I execute them using osql3() or some combination of osql3() and oexec()? A different dml statement, lock table, apparently works using just osql3().

I have to say that I do not find the design of the OCI library especially well done. The interface routines suffer from the goal of having identical interfaces between C, Cobol and Fortran. The data structures seem to have been defined from an assembly programmer's point of view: the elements of the lda structure are a subset of those of the cda structure, and have the same offsets, even though the structures play entirely different roles. The hda structure should be part of the lda, since there is a one-to-one correspondence between the two (remember basic normalization theory?).

Conversion between long raw and long should not be inhibited (just use the identity map). The way failures are handled is pretty confusing, especially since there are so many of them, some aren't even failures at all (i.e., the wierd way to check the result of a ofen() call). Why does Oracle use a different set of calls for the pro*.. preprocessors?

The OCI library (on multi-tasking machines) should be coded to allow asynchronous usage (sort of RPC-like, with explicit command sending and explicit reply receiving, after selecting some file descriptor for read), so you could multithread under X11 etc. Is this any better in v7 OCI?

Konrad Received on Wed Feb 23 1994 - 23:39:38 CET

Original text of this message