Solved

using jdbc to connect to MSSQL SERVER

Posted on 1997-05-07
1
205 Views
Last Modified: 2012-06-21
 I am developing an application using jdbc-odbc driver which talks to
the MS SQL Server(Database).

>         The following statement  - SELECT * FROM TABLENAME

>         works fine sometimes and doesn't work sometime from the application.

>         The following is the error message displayed

> java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Connection is busy
wit
> h results for another hstmt
>         at sun.jdbc.odbc.JdbcOdbc.createSQLException(JdbcOdbc.java:3669)
>         at sun.jdbc.odbc.JdbcOdbc.standardError(JdbcOdbc.java:3822)
>         at sun.jdbc.odbc.JdbcOdbc.SQLExecDirect(JdbcOdbc.java:1063)
>         at sun.jdbc.odbc.JdbcOdbcStatement.execute(JdbcOdbcStatement.java:214)
>         at
sun.jdbc.odbc.JdbcOdbcStatement.executeQuery(JdbcOdbcStatement.java:1
> 39)

> I would appreciate an early response to the above problem.

> Thanks
> Padma

0
Comment
Question by:padma
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 

Accepted Solution

by:
wcrosman earned 100 total points
ID: 1220221
The problem here is that you've initiated two SQL querries without
fully dealing with the results returned by the prior querry.  Either
use a loop to deal with the results or issue a db_canquery command
to kill the awaiting results.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
jdbc error in jsp application 20 88
spring jars download 1 67
maven not picking latest jar instead picking old jar from .m2 12 74
What is the use of Forwarding Class in java 1 52
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
The viewer will learn how to implement Singleton Design Pattern in Java.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Suggested Courses

732 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question