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

Home -> Community -> Mailing Lists -> Oracle-L -> OCI Questions.

OCI Questions.

From: Alexander Olefirenko <bofh_at_rbc.ru>
Date: Wed, 13 Sep 2000 10:06:53 +0400
Message-Id: <10617.116802@fatcity.com>


Helo !
I'm in developing lib for Linux (some information at ocicpplib.sourceforge.net) to provide a simple interface to Oracle 8/8i from c++ and i have some problems understanding OCI. The questions should be simple for you but i don't find out how to solve it : 1) Fetching numbers: at the moment i
doing next thing: I take a number precision and if i's not null allocates buffer of length precision+1 and request SQLT_STR for number. If it's 0 assume 255 bytes long buffer is enough but it not looks like a right way :( Can u tell me how u solve this problem ? 4) Using OCIAttrGet(...OCI_ATTR_NAME) i passint the pointer to pointer to buffer and get a pointer to some buffer containing attribute name. The only way to do that safe in single-threaded application is static buffer somethere deeper inside OCIAttrGet().But I can't understand how it works in multi-threaded environment.Should i do free() on returned pointer or not ? I'm asking it because using JDBC OCI with Oracle 8 i've noticed memory leaks. Using thin drivers solve this problem .. but ...

I Thank you beforehand for your help.

--
Regards, Olefirenko Alexander
RBC Co. http://www.rbc.ru
+8 095 935-20-01(207,209)
Received on Wed Sep 13 2000 - 01:06:53 CDT

Original text of this message

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