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

Add method RelBuilder.empty, and rewrite LIMIT 0 to it

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.6.0
    • Component/s: None
    • Labels:
      None

      Description

      Add a method RelBuilder.empty(), a new method that returns an empty relation. The default implementation returns a Values with no rows, but schema-on-query systems such as Drill might override the empty method to read schema from an input at query time.

      RelBuilder.filter(false) and RelBuilder.limit(0, 0) should simplify to empty().

        Issue Links

          Activity

          Show
          julianhyde Julian Hyde added a comment - Fixed in http://git-wip-us.apache.org/repos/asf/calcite/commit/ee283cad .
          Hide
          julianhyde Julian Hyde added a comment -

          Resolved in release 1.6.0 (2016-01-22).

          Show
          julianhyde Julian Hyde added a comment - Resolved in release 1.6.0 (2016-01-22).

            People

            • Assignee:
              julianhyde Julian Hyde
              Reporter:
              julianhyde Julian Hyde
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development