dcsimg
java.sql.SQLException: [SQL0519] Prepared statement STMT0002 in use.
4 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Sean_Sullivan
Posted On:   Friday, March 8, 2002 07:10 PM

I am using IBM's AS400 Toolkit in conjunction with IBM Websphere 3.5 I am encountering this error message: java.sql.SQLException: [SQL0519]Prepared statement STMT0002 in use. at com.ibm.as400.access.JDError.throwSQLException(JDError.java:351) at com.ibm.as400.access.JDServerRowCache.fetch(JDServerRowCache.java:225) at com.ibm.as400.access.JDServerRowCache.fetch(JDServerRowCache.java:171) at com.ibm.as400.access.JDServerRowCache.next(JDServerRowCache.java:472) at com.ibm.as400.access.AS400JDBCResultSet.next(AS400JDBCResultSet.java:1213) at ... What does this error mean? How can I fix it?    More>>


I am using IBM's AS400 Toolkit in conjunction with IBM Websphere 3.5



I am encountering this error message:




			
java.sql.SQLException: [SQL0519]Prepared statement STMT0002 in use.
at com.ibm.as400.access.JDError.throwSQLException(JDError.java:351)
at com.ibm.as400.access.JDServerRowCache.fetch(JDServerRowCache.java:225)
at com.ibm.as400.access.JDServerRowCache.fetch(JDServerRowCache.java:171)
at com.ibm.as400.access.JDServerRowCache.next(JDServerRowCache.java:472)
at com.ibm.as400.access.AS400JDBCResultSet.next(AS400JDBCResultSet.java:1213)
at ...


What does this error mean? How can I fix it?    <<Less

Re: java.sql.SQLException: [SQL0519] Prepared statement STMT0002 in use.

Posted By:   Sean_Sullivan  
Posted On:   Sunday, April 21, 2002 06:26 PM

I resolved this issue by upgrading to IBM's JTOpen 3.0

Re: java.sql.SQLException: [SQL0519] Prepared statement STMT0002 in use.

Posted By:   Sean_Sullivan  
Posted On:   Wednesday, March 13, 2002 06:31 PM

Some additional information about our application:



  • the application runs in Websphere 3.5

  • the application is multi-threaded

  • the application has auto-commit enabled for the JDBC driver

Re: java.sql.SQLException: [SQL0519] Prepared statement STMT0002 in use.

Posted By:   Sean_Sullivan  
Posted On:   Wednesday, March 13, 2002 06:30 PM

I obtained some information regarding this issue. This information comes from IBM's JTOpen web message board.


-------

RE: java.sql.SQLException: [SQL0519]Prepared statement STMT0002 in use.

we saw this error too, its been a couple of months since IBM got us a fix for
it. i beleive it was a bug with the lazycursor option, not sure. we
turned off the lazycursor option and the bug never showed up again. not
sure when/if they are going to ever put the bug fix into the jtopen code......
i "think" this is the same bug, like i said, it was a couple of months since
i have seen it.

-------


RE: java.sql.SQLException: [SQL0519]Prepared statement STMT0002 in use.


Fix available in JTOpen 3.0

There's a fix for the problem Derek describes in JTOpen 3.0. It was a bug
that you would only see if you had "lazy close=true" (not the default) and
a fair amount of multi-threading in your application.

Does that match what the two of your applications are?

Thanks,
Susan Funk - IBM Toolbox for Java team

Re: java.sql.SQLException: [SQL0519] Prepared statement STMT0002 in use.

Posted By:   Sean_Sullivan  
Posted On:   Monday, March 11, 2002 02:31 PM


I obtained some additional information regarding this issue.



The code "SQL0519" is documented here:



ftp://ftp.software.ibm.com/ps/products/db2/info/vr5/db2m0e51.pdf




This is what SQL0519 means:




Cause: The application program attempted to prepare the SELECT
or VALUES statement for the specified
cursor when that cursor is already
open.

The statement cannot be prepared. The
cursor was not affected.

Action: Correct the application program
so it does not attempt to prepare the
SELECT or VALUES statement for a cursor
that is open.

sqlcode: -519
sqlstate: 24506


About | Sitemap | Contact