• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Invalid state, the Statement object is closed.

 
Krishna Sundaresan
Greenhorn
Posts: 2
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In one our production servers the execution of a batch fails consistently and the following stack trace snippet is observed. The problem does not occur on other servers with similar configuration.



The application is single-threaded and does not use connection pooling of any sort. The chance that the statement object was closed between the addBatch and executeBatch were executed is nil. We are using JTDS driver 1.2 interfacing with SQL Server 2000. The database server is up and accepting connections.

Any clues on what might be happening is greatly appreciated.
 
ujjwal soni
Ranch Hand
Posts: 403
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Welcome to javaranch.

Can you post some code where you are connecting with Database server ?
 
Krishna Sundaresan
Greenhorn
Posts: 2
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The connection is being provided by the following code. The URL that is being passed in is a JDBC URL.

 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic