Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-22292

Implement Hypothetical-Set Aggregate Functions

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 4.0.0-alpha-1
    • UDF
    • None

    Description

      <hypothetical set function> ::=
        <rank function type> <left paren>
        <hypothetical set function value expression list> <right paren>
        <within group specification>
      
      <rank function type> ::=
        RANK
        | DENSE_RANK
        | PERCENT_RANK
        | CUME_DIST
      

      Example:

      CREATE TABLE table1 (column1 int);
      INSERT INTO table1 VALUES (NULL), (3), (8), (13), (7), (6), (20), (NULL), (NULL), (10), (7), (15), (16), (8), (7), (8), (NULL);
      
      SELECT rank(6) WITHIN GROUP (ORDER BY column1) FROM table1;
      
      2
      

      Attachments

        1. HIVE-22292.8.patch
          98 kB
          Krisztian Kasa
        2. HIVE-22292.8.patch
          98 kB
          Krisztian Kasa
        3. HIVE-22292.8.patch
          98 kB
          Krisztian Kasa
        4. HIVE-22292.8.patch
          98 kB
          Krisztian Kasa
        5. HIVE-22292.7.patch
          98 kB
          Krisztian Kasa
        6. HIVE-22292.7.patch
          98 kB
          Krisztian Kasa
        7. HIVE-22292.6.patch
          98 kB
          Krisztian Kasa
        8. HIVE-22292.5.patch
          98 kB
          Krisztian Kasa
        9. HIVE-22292.4.patch
          98 kB
          Krisztian Kasa
        10. HIVE-22292.3.patch
          97 kB
          Krisztian Kasa
        11. HIVE-22292.2.patch
          97 kB
          Krisztian Kasa
        12. HIVE-22292.1.patch
          90 kB
          Krisztian Kasa

        Issue Links

          Activity

            People

              kkasa Krisztian Kasa
              kkasa Krisztian Kasa
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: