Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.tools -> Re: Dynamic Sql Method 4

Re: Dynamic Sql Method 4

From: Pierre Charpenay <pcharpenay_at_unilog.fr>
Date: 2000/06/20
Message-ID: <394F5971.9C1AF242@unilog.fr>#1/1

Anirban Chattopadhyay a écrit :
>
> I am trying to use the Dynamic SQL Method 4 ( chapter 14/15 Pro*C/C++
> Precompiler manual)in my Pro*C application and facing the following
> problem:
>
> When i use Array fetch into the SQL Descriptor area it core dumps (on
> Sun Solaris) when the array size is > 100 or so. Oracle has supplied
> with a few samples - i modelled it on sample12.pc, which is very simple
> - coercing all data types to Character (i.e the T[i] is set to 1). I
> cannot coerce all data types to 1, instead i need to coerce all number
> datatype to either int ( 3 ) or float ( 4 ), depending on the scale. I

May be the problem comes from the L[i] value which give to Oracle the size of each data in the array. So, for int or float (double would be more accurate), you have to give respectively "sizeof(int)" and "sizeof(float)" (and your arrays, somethings like int my_int[FETCH_SIZE] and float my_float[FETCH_SIZE]). If you don't, it will probably fail somewhere.

> have a feeling, the core dumping is due to this. Is this a known bug and
> a patch available??
>
> Does anybody have any clue on this.
>
> thanks in advance. Please cc to anirban_at_ans.net
>
> anirban
 

-- 
 Pierre CHARPENAY
Received on Tue Jun 20 2000 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US