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

Home -> Community -> Usenet -> c.d.o.server -> ProC Declaring host arrays in a separate class

ProC Declaring host arrays in a separate class

From: dreadlord76 <dreadlord76_at_yahoo.com>
Date: 29 Apr 2002 11:24:25 -0700
Message-ID: <e6ddea21.0204291024.36a8cfdf@posting.google.com>


I need to convert an existing single-threaded ProC application to be multi-threaded. We use host arrays to speed up bulk processing. Currently, host arrays are declared in a global scope:

EXEC SQL BEGIN DECLARE SECTION;
    long my_sample_id[100];
EXEC SQL END DECLARE SECTION; What I like to do, is to put these arrays in a helper class, and have instances of the helper class associated with each sql_context. To do this, I started by creating a Header file for the helper class.

When the VC++ compiler tries to compile after ProC got through the .pc file, the compiler barfs on the "EXEC SQL BEGIN DECLARE SECTION;" in the header file.

So is what I need to do possible? Can I declare host variables in a class so I can have multiple instances of them, instead of declaring them globally, or make them class specific?

I can declare them in the scope of the class using the host arrays, but not all instances of the class needs the host arrays, and the memory allocation would be pretty large and wasteful.

Thanks in advance!

dreadlord76 Received on Mon Apr 29 2002 - 13:24:25 CDT

Original text of this message

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