You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "Krisztian Kasa (Jira)" <ji...@apache.org> on 2019/11/04 07:14:00 UTC
[jira] [Updated] (HIVE-22292) Implement Hypothetical-Set Aggregate
Functions
[ https://issues.apache.org/jira/browse/HIVE-22292?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Krisztian Kasa updated HIVE-22292:
----------------------------------
Status: Open (was: Patch Available)
> Implement Hypothetical-Set Aggregate Functions
> ----------------------------------------------
>
> Key: HIVE-22292
> URL: https://issues.apache.org/jira/browse/HIVE-22292
> Project: Hive
> Issue Type: Improvement
> Components: UDF
> Reporter: Krisztian Kasa
> Assignee: Krisztian Kasa
> Priority: Major
> Fix For: 4.0.0
>
> Attachments: HIVE-22292.1.patch, HIVE-22292.2.patch, HIVE-22292.3.patch, HIVE-22292.4.patch, HIVE-22292.5.patch, HIVE-22292.6.patch
>
>
> {code}
> <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
> {code}
> Example:
> {code}
> 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);
> {code}
> {code}
> SELECT rank(6) WITHIN GROUP (ORDER BY column1) FROM table1;
> {code}
> {code}
> 2
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)