Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-1574

NullPointerException in UPDATE with COALESCE and subquery

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 10.0.2.0, 10.0.2.1, 10.0.2.2, 10.1.1.0, 10.1.2.1, 10.1.3.1, 10.1.3.2, 10.1.3.3, 10.2.1.6
    • 10.2.1.6
    • SQL
    • None
    • Java 1.5.0_06
    • Normal

    Description

      The following statements generate a NullPointerException:

      CREATE TABLE t1 (i INTEGER);
      CREATE TABLE t2 (i INTEGER);

      UPDATE t1
      SET i = COALESCE(
      (SELECT i FROM t2 WHERE t2.i=t1.i),
      0);

      Any further SQL statements generate an internal error in RawStore, e.g.:
      SELECT * FROM t1;

      Attachments

        1. derby1574.diff
          2 kB
          Dag H. Wanvik
        2. derby1574-2.diff
          4 kB
          Dag H. Wanvik
        3. derby1574-2.stat
          0.3 kB
          Dag H. Wanvik
        4. predicatePushdown.diff
          0.7 kB
          Dag H. Wanvik

        Issue Links

          Activity

            People

              dagw Dag H. Wanvik
              chdh@inventec.ch Christian d'Heureuse
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: