Derby
  1. Derby
  2. DERBY-215

Correlation name not allowed for updatable columns in updatable cursors

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 10.1.1.0
    • Fix Version/s: None
    • Component/s: SQL
    • Urgency:
      Normal
    • Bug behavior facts:
      Deviation from standard

      Description

      Derby supports positioned updates via direct SQL and via updatable resultset JDBC apis.

      Derby's implementation of updatable resultset JDBC api does not allow use of correlation names for updatable columns. For eg, on a FORWARD_ONLY, CONCUR_UPDATABLE Statement object, you can't issue statement.executeQuery("select c11 as col1, c12, c13 from t1 for update of c11, c12"). The use of correlation name col1 for updatable column c11 will result in an exception.

      The check for this correlation name for updatable resultset jdbc api was earlier in the run time code (ResultSet.updateXXX methods) but that check had performance implications. To address that, the check has been moved to compile time in the CursorNode.java (this went in as revision 159758). But CursorNode.java handles postioned updates coming though both SQL and through updatable resultset jdbc apis and hence as a side effect of moving the check to compile time, the positioned update through direct SQL can also NOT use correlation name for updatable columns. This might impact existing applications.

        Activity

          People

          • Assignee:
            Unassigned
            Reporter:
            Mamta A. Satoor
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:

              Development