Hi
We have just migrated to DB2 Version 8 and are now using the JDBC Type 4
driver. This is when the problems started.
The first problem is when running a simple query (SELECT * from
CUSTOMER) the following exception is printed out in the output window:
com.ibm.db2.jcc.b.SqlException: Invalid operation: result set closed
Query 1 elapsed time (seconds) - Total: 0.078, SQL query: 0.047,
Building output: 0.031
In 1.2b6, the results of the query are still printed out in the results
window. In 2.0rc1 the results of the query do not even display. Using
the "Objects" view and drilling down, Squirrel displays the table data
in both versions without any issue.
I have written a simple class that creates a JDBC connection in the same
way. When I run the query, no errors/exceptions occur. Although I only
retrieve the first column from the result set but I do not believe this
is related to the issue.
The second problem is as follows. When running an update as follows:
UPDATE CUSTOMER SET SEGMENT = 777 WHERE ID IN (SELECT CUSTOMERID from
CASEBASIC)
the following is displayed in the output window:
13 Rows Updated
Query 1 elapsed time (seconds) - Total: 0, SQL query: 0, Building output: 0
Error: java.lang.StringIndexOutOfBoundsException: String index out of
range: -35
This seems to actually update the records in 1.2b6 but not in 2.0rc1.
Once again I wrote a simple class to run the update which displayed no
errors or exceptions.
My class ran both of the above items as Statements and
PreparedStatements with no issues. Could someone give me a pointer as to
where I should start looking for the solutions to the problems I am
encountering. Maybe even a quick explanation as to what Squirrel does
once it executes a query in the SQL view.
Perhaps there is a bug in the JDBC driver metadata methods that Squirrel
calls? Note that the issues above do not appear when running the queries
using a JDBC Type 2 driver (which is a different class completely).
However I cannot access all my databases using the Type 2 drivers for
other non-technical reasons, so I would like to get this working.
TIA
Regards,
Karim
___________________________________________________________
Important Notice:
Authorised Financial Services Provider
Important restrictions, qualifications and disclaimers
("the Disclaimer") apply to this email. To read this click on the
following address or copy into your Internet browser:
http://www.absa.co.za/disclaimer
The Disclaimer forms part of the content of this email in terms of
section 11 of the Electronic Communications and Transactions
Act, 25 of 2002.
If you are unable to access the Disclaimer, send a blank e-mail
to dis...@ab... and we will send you a copy of the
Disclaimer.
|