jim@bilpin.UUCP (Jim G) (03/31/89)
#{ v_databases.5 }
Further to my original posting on this a few weeks ago, subsequent to
which progress has been made ...
We're writing a group of functions to interface between an Oracle
back-end and a suite of C programs originally written for a non-Oracle
file structure. We're using 'dynamic SQL', as the functions are to be
generally applicable to all applications within the suite. To handle
'previous row' we are having to cache the old rows read (max 3 previous)
as there is no equivalent SQL function.
Now, the question is, how to move the row data to the cache, and shuffle
it up and down efficiently? The SQLDA structure allocated by sqlald() is
just a load of pointers which, for any specific cursor, will always have
the same values - the data items pointed to could be all over the place.
Does anyone know how sqlald() allocates its space for the descriptor
area, and whether it would be feasible to memcpy() a block containing
all the column data for the current row to the cache, and then copy it
back to the real descriptor area if that row became current again?
--
<Path: mcvax!ukc!icdoc!bilpin!jim> <UUCP: jim@bilpin.uucp>
Always look on the dark side -
you'll never be disappointed, and often pleasantly surprised.