Issue Details (XML | Word | Printable)

Key: DERBY-1314
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Knut Anders Hatlen
Reporter: Knut Anders Hatlen
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Derby

Differences between client and embedded when invoking stored procedures using Statement.executeUpdate()

Created: 10/May/06 08:30 PM   Updated: 18/Sep/06 03:26 PM
Return to search
Component/s: JDBC
Affects Version/s: 10.2.1.6
Fix Version/s: 10.2.1.6

Time Tracking:
Not Specified

File Attachments:
  Size
Text File Licensed for inclusion in ASF works derby-1314-v1.diff 2006-06-13 06:38 PM Knut Anders Hatlen 4 kB
Text File Licensed for inclusion in ASF works derby-1314-v1.stat 2006-06-13 06:38 PM Knut Anders Hatlen 0.2 kB
Issue Links:
Reference
 

Issue & fix info: Patch Available, Release Note Needed
Resolution Date: 23/Jun/06 07:23 PM


 Description  « Hide
When invoking a stored procedure using Statement.executeUpdate(), the
client driver and the embedded driver behave differently.

If the stored procedure does not return any result set, the embedded
driver returns 0, whereas the client returns -1.

If the stored procedure returns one or more result sets, the embedded
driver returns -1, whereas the client fails with an exception.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Repository Revision Date User Message
ASF #414795 Fri Jun 16 10:17:14 UTC 2006 kahatlen DERBY-501: Client and embedded drivers differ on invoking a procedure
that returns a single Dynamic resultSet using CallableStatement.executeQuery()

This patch modifies EmbedStatement.processDynamicResults() so that it
returns the number of dynamic results instead of a
boolean. EmbedStatement.executeStatement() uses this number to decide
whether an exception is to be raised. With this change, the
executeQuery and executeUpdate parameters are no longer needed in
GenericPreparedStatement.execute().

ProcedureTest.junit is now enabled in derbyall (all frameworks). Seven
of the test cases run in the embedded framework only, but I expect all
of them to succeed with the client driver after DERBY-1314 and
DERBY-1364 have been fixed.
Files Changed
MODIFY /db/derby/code/trunk/java/engine/org/apache/derby/iapi/sql/PreparedStatement.java
MODIFY /db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedResultSet.java
MODIFY /db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/suites/jdbcapi.runall
MODIFY /db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/execute/GenericTriggerExecutor.java
MODIFY /db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedStatement.java
MODIFY /db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/GenericPreparedStatement.java

Repository Revision Date User Message
ASF #416696 Fri Jun 23 12:19:51 UTC 2006 kahatlen DERBY-1314: Differences between client and embedded when invoking
stored procedures using Statement.executeUpdate()

Make executeUpdate() return 0 on the client when executing a stored
procedure.
Files Changed
MODIFY /db/derby/code/trunk/java/client/org/apache/derby/client/am/Statement.java
MODIFY /db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/ProcedureTest.java
MODIFY /db/derby/code/trunk/java/client/org/apache/derby/client/am/PreparedStatement.java

Repository Revision Date User Message
ASF #447505 Mon Sep 18 19:06:53 UTC 2006 rhillegas DERBY-1860: Incorporate release notes for DERBY-1295, DERBY-1314, and DERBY-1323 submitted by Fernanda, Knut Anders, and Dag.
Files Changed
MODIFY /db/derby/code/branches/10.2/RELEASE-NOTES.html