I am running a Java application which has multiple sql queries including update and insert.Basically I am connecting to a MS Sql Server.
But I am getting the following error.
Error Details - [Microsoft][ODBC SQL Server Driver]Connection is busy with results for another hstmt.
I am getting this error only when my Jave application is accessing the database to do this update/insert. At the same time when another application is updating the same database.
Please let me know if I need to post my piece of code which has the JDBC operations or this error is due to the database contention when two apps working on the same table.
Can you please let me know a work around for this kind of sql exception.
Originally posted by Prem Bhazee: Yes, I am using different connection objects for the concurrent queries and I am also closing both the connection objects.
Bhazee
Are you sure? You call getConnection(), but where do you check that it returns two different instances?