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

Correct Javadoc example in SqlStaticAggFunction#constant

    XMLWordPrintableJSON

Details

    • Task
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.35.0, 1.36.0, 1.37.0
    • 1.38.0
    • core

    Description

      The Javadoc in SqlStaticAggFunction#constant says:

      GROUPING(deptno) expands to literal 1 if the aggregate has GROUP BY deptno
      

      However, this "1" seems incorrect (it should rather be "0"). If we look at the actual implementation of this logic in SqlGroupingFunction#constant, or this test agg.iq, it seems in these cases the GROUPING is expanded to a constant 0.

      Attachments

        Issue Links

          Activity

            People

              rubenql Ruben Q L
              rubenql Ruben Q L
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: