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

Support distinct aggregates in window functions

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.0.0-incubating
    • Fix Version/s: 1.13.0
    • Component/s: None
    • Labels:
      None

      Description

      Migrated from https://groups.google.com/forum/#!topic/optiq-dev/8xE3PriKXmI

      Does Optiq support Windowing func with Distinct?

      Ex: select avg(distinct c_int) over(PARTITION BY key ORDER BY value ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW) as p from t1;
      Hive support Windowing functions with "Distinct" (UDAF with Distinct).

      I am using "m_cluster.getRexBuilder().makeOver" to build window.
      Optiq doesn't seems to support distinct on Windowing Functions.
      Am i missing something?

        Issue Links

          Activity

          Hide
          julianhyde Julian Hyde added a comment -

          Fixed in http://git-wip-us.apache.org/repos/asf/calcite/commit/aed5bca7. (Includes parser and SQL-to-RelNode support, but engines including EnumerableWindow currently ignore the flag.)

          Thanks for the PR, radu!

          Duplicated by CALCITE-1740.

          Show
          julianhyde Julian Hyde added a comment - Fixed in http://git-wip-us.apache.org/repos/asf/calcite/commit/aed5bca7 . (Includes parser and SQL-to-RelNode support, but engines including EnumerableWindow currently ignore the flag.) Thanks for the PR, radu ! Duplicated by CALCITE-1740 .
          Hide
          jcamachorodriguez Jesus Camacho Rodriguez added a comment -

          Resolved in release 1.13.0 (2017-06-26).

          Show
          jcamachorodriguez Jesus Camacho Rodriguez added a comment - Resolved in release 1.13.0 (2017-06-26).

            People

            • Assignee:
              julianhyde Julian Hyde
              Reporter:
              vladimirsitnikov Vladimir Sitnikov
            • Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development