db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dag H. Wanvik (JIRA)" <derby-...@db.apache.org>
Subject [jira] Commented: (DERBY-1323) Detectability methods rowUpdated, rowInserted, rowDeleted can be called from illegal states in both clients
Date Mon, 18 Sep 2006 15:59:59 GMT
    [ http://issues.apache.org/jira/browse/DERBY-1323?page=comments#action_12435504 ] 
Dag H. Wanvik commented on DERBY-1323:

Release note for this issue:


For a JDBC ResultSet with type TYPE_FORWARD_ONLY, the methods
rowUpdated, rowDeleted and rowInserted could previously be called
while not on a row, i.e. before positioning in the result set, while
on insertRow, after updateRow before new positioning, after deleteRow
before new positioning and when after last row. This is now


Calls to any of these methods while not on a row will now throw
SQLException with SQLState 24000.


Derby now disallows these calls when not on a row.


Change the application to not call these methods unless on a row. Note
that using them at all is rather meaningless for a ResultSet of type
TYPE_FORWARD_ONLY since the returned result will always be 'false'.
This is because once you modify a row, it can no longer be accessed,
you need to move to the next row, if there is one, to get a new
current row. Presently in Derby, these methods are only really
meaningfully useed for result sets of type TYPE_SCROLL_INSENSITIVE and
of concurrency CONCUR_UPDATABLE in which case updated and deleted rows
can be detected.



> Detectability methods rowUpdated, rowInserted, rowDeleted can be called from illegal
states in both clients
> -----------------------------------------------------------------------------------------------------------
>                 Key: DERBY-1323
>                 URL: http://issues.apache.org/jira/browse/DERBY-1323
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC, Network Client
>    Affects Versions:
>            Reporter: Dag H. Wanvik
>         Assigned To: Dag H. Wanvik
>            Priority: Minor
>             Fix For:
>         Attachments: DERBY-1323-1.diff, DERBY-1323-1.stat, DERBY-1323-2.diff, DERBY-1323-2.stat,
> Please see enclosed repro.
> These detectability methods fail to check that they can be called in
> some states. In the repro, calls are allowed while on insert row and
> when after last row. These should both fail. Both clients have the
> same problem. All three detectability methods have the same problem.
> (repro only shows it for a subset of the cases).

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message