Post by rajsr » Thu, 03 Sep 1998 04:00:00

Hi Guys,

I'am trying to develop a multithreaded application with multiple
database connection viz per thread connection using OCI calls. According
to the oracle oci documentation it is possible using opinit with
OCI_EV_TSF parameter.But I'am not able to run the application
successfully. What I really want to make sure is that whether Oracle-7.3
for NT  supports this or not.

Thanks in advance,



Destiny is not a matter of chance; it is matter of choice. It is not
something to
be waited for; but rather something to be achieved.

                 ~ William Jennings Bryan ~


30c,Hewlett Packard-ISO,
Cunningham Road,


  Srisoft Technology Pvt. Ltd., Koramangala,Bangalore.


1. MultiThreaded App doesn't release user connections to SQLServer DB

    I have recently finished writing an C++(VC5.0) application that runs as
an NT 4.0 service.  It recieves a Datagram from another application, and if
necessary spawns a thread that does multiple Database queries using Stored
Procedures.  Each time it executes a stored procedure, by calling Open(), it
must use another SQL Server user connection, then when it is done with the
Recordset, it calls Close() against the SP.
    The problem that I am encountering, is that all of the user connections
are not being released.  When a thread is spawned, it uses no more than 2
connections simultaneously, however, it only releases one of them.  Myself
and a collegue have been through the code multiple times to verify that we
are closing every recordset that is opened.
    An example is, we request 10 files be downloaded, the client program
sends 10 requests for files.  Each request spawns a thread.  The thread
opens a recordset to verify the client is valid, then closes it.  Then it
opens a recordset to find the file that was requested, and closes it.  It
does the same to read information about the file from other tables and then
sends a datagram back to the client and waits for an ack.  when it gets the
ack, it terminates the thread.   Currently I create individual instances of
each recordset that I use before I use them in each thread.
    Is there a multithreading trick with ODBC that I should be using?
    Shane Fetters

2. Help! INGRES installation problems.

3. multithreaded Connections?

4. Should I use a CURSOR??? Newbie

5. Multithreaded ODBC connection

6. Would this work?

7. esql/c multithreaded connection handling question...

8. US-OR Portland Oracle Data Warehousing PL/SQL

9. Is ADO connection object multithreaded?

10. Asynchronous, multithreaded OLE DB provider in VB

11. Multithreaded JDBC Driver for mySQL DB

12. ODBC vs DB-lib for multithreaded server

13. Multithreaded examples with OLE DB