Weird Parameters for obndrv & odefin in OCI (C/Oracle 7)

From: Raoul <rherborg_at_yahoo.de>
Date: Fri, 07 May 1999 15:11:53 +0200
Message-ID: <3732E699.3A381362_at_yahoo.de>



Hi there,

I am some newbee trying to get smallint & char data out of an Oracle database using the Oracle Call Interface from C on a solaris machine. Now there are these two commands obndrv and odefin with pretty strange parameters:

obndrv(&cda, ":szen_nr", -1, (ub1 *) &szen_nr,

  	(sword) sizeof (sword), INT, -1, (sb2*) 0,
  	(text *) 0, -1, -1)

odefin(&cda, 1, (ub1 *) &kat_nr, 

(sword) sizeof (ub4), SQLT_INT,-1, (sb2 *) -1,
(text *) 0, 0, -1,(sword) 0, (sword) 0 )

the latter works more or less and I am able to apply it to other fields in the database as well. It's just that - based on the Programmer's Guide - I have no clue how to set the parameters correctly, especially those in the second and third lines. All I want to do is to get these int or char values, nothing fancy.

If anybody could just confirm that what I figuerd out by examples and copy & paste is more or less correctly it would be of great help.

Tanks a lot.

        Raoul Received on Fri May 07 1999 - 15:11:53 CEST

Original text of this message