Uploaded image for project: 'Calcite'
  1. Calcite
  2. CALCITE-7230

Compiler rejects comparisons between NULL and a ROW value

    XMLWordPrintableJSON

Details

    Description

      This is exhibited by the following SqlValidatorTest:

          sql("SELECT COALESCE(NULL, ROW(1))")
              .withValidatorConfig(c -> c.withCallRewrite(false))
              .type("RecordType(RecordType(INTEGER EXPR$0) EXPR$0) NOT NULL");
      

      The program is rejected with:

      From line 1, column 8 to line 1, column 29: Parameters must be of the same type

      The sad thing is that I already fixed a similar issue in CALCITE-7195, but my fix was insufficient.

      Attachments

        Issue Links

          Activity

            People

              mbudiu Mihai Budiu
              mbudiu Mihai Budiu
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: