Hi,

Using H2 (h2-2012-05-23) with JDBC, I am facing the following issue:

I am sending a user-defined statement, which may contain multiple 
operations, where we are eventually interested in the returned resultset of 
the last statement.

The problem is that it seems those JDBC methods don't work:
- Statement.getMoreResults() returns false
- Statement.getUpdateCount() returns -1

Furthermore, the first "Statement.getResultSet()" returns a result if it 
was a select, while in our case we want the last one. The reason is that if 
there is more than one statement, it is because the user created tables 
and/or performed some preliminary operations, and finally returns the 
result.

Am I missing something or is it not supported? Should I be somehow manually 
parsing the SQL text to split it around the ";" and execute the split 
queries separately (which I believe can be error prone)?

Cheers,
-Christopher

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/h2-database/-/xk3SbJmwRmQJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en.

Reply via email to