Connection is busy - Why? 
Author Message
 Connection is busy - Why?

I am using CRecordset without deriving it and get
values via GetFieldValue. I get exception with
this description "Connection is busy with results
for another hstmt". The exception is only when
have two (or more) connections active.
eg.

CRecordset rs1( db );
rs1.Open(.....);
...
CRecordset rs2( db );
rs2.Open(.....);
...
rs1.Close();
rs2.Close();

The exception is thrown when opening the rs2.
The exception is even thrown when calling db->ExecuteSQL( .... ) instead of
opening rs2.
I took a look at KB. Microsoft say in Article ID: Q175904 they have a bug
in MS SQL 6.5 and ODBC - when opening multiple
connections from different threads you get this message.
My application has multiple threads, but these recordsets are always in one
thread (It is not an application main thread but worker).

Could you give me an idea where could be the problem?

Thanks in advance,
Stefan Tchekanov
----------



Sat, 27 Jul 2002 03:00:00 GMT  
 Connection is busy - Why?
Hi All,
I have a problem accessing MS SQL Server database via ODBC.

I am using CRecordset without deriving it and get
values via GetFieldValue. I get exception with
this description "Connection is busy with results
for another hstmt". The exception is only when
have two (or more) connections active.
eg.

CRecordset rs1( db );
rs1.Open(.....);
...
CRecordset rs2( db );
rs2.Open(.....);
...
rs1.Close();
rs2.Close();

The exception is thrown when opening the rs2.
The exception is even thrown when calling db->ExecuteSQL( .... ) instead of
opening rs2.
I took a look at KB. Microsoft say in Article ID: Q175904 they have a bug
in MS SQL 6.5 and ODBC - when opening multiple
connections from different threads you get this message.
My application has multiple threads, but these recordsets are always in one
thread (It is not an application main thread but worker).

I do not have this problem when the database is Oracle 8.

Could you give me an idea where could be the problem?

Thanks in advance,
Stefan Tchekanov
----------



Sun, 28 Jul 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Connection is busy - Why?

2. Connection is busy with results - VC++ 1.52, SQL Server 6.5, ODBC

3. ExecuteSql Error: connection busy

4. Terminating ODBC connection whilst query is busy?

5. BUG: Multiple threads Cause Connection Busy Error in the Driver

6. error: "Connection is busy..."

7. Connection is busy with results for another htstmt

8. Connection is busy with results from another hstmt

9. VC++ 1.52, Connection is busy with results - SQL Server 6.5, ODBC

10. printer-busy or not busy?

11. Why am I getting an ExecutionEngineException?

12. Why am I being ignored ???

 

 
Powered by phpBB® Forum Software