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

EnumerableUnion should preserve ordering when all inputs have the same collation

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • None
    • 1.27.0
    • None
    • None

    Description

      For query:

      select name from sales_dept
      union 
      select name from it_dept
      order by mgr
      
      

      We could generate a plan based on https://issues.apache.org/jira/browse/CALCITE-4017:

      EnumerableUnion
          EnumerableProject
              EnumerableSort
                 EnumerableTableScan[name="sales_dept"]
          EnumerableProject
              EnumerableSort
                 EnumerableTableScan[name="it_dept"]
      

      So EnumerableUnion should preserve ordering when all input have the same collation to make sure result of query is correct.

      Attachments

        Issue Links

          Activity

            People

              amaliujia Rui Wang
              amaliujia Rui Wang
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: