[ https://issues.apache.org/jira/browse/HIVE-8388?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14485654#comment-14485654 ]
Clif Kranish commented on HIVE-8388: ------------------------------------ Using Hive 0.14 and this option with hortonworks sample file and simple query works select code, description from sample_07 order by 1; But with aggregation fails select max (salary) from sample_07 group by salary order by 1; Error: Error while compiling statement: FAILED: SemanticException [Error 10004]: Line 1:12 Invalid table alias or column reference 'salary': (possible column names are: _c0) (state=42000,code=10004) > Support GROUP/ORDER BY column references by ordinal position > ------------------------------------------------------------ > > Key: HIVE-8388 > URL: https://issues.apache.org/jira/browse/HIVE-8388 > Project: Hive > Issue Type: Improvement > Components: SQL > Reporter: John Scheibmeir > Assignee: Gunther Hagleitner > Priority: Minor > > Allow user to reference the group by or order by column by the desired > column's ordinal position > Support syntax such as: > select t.col1, sum(t.col2) from my_table t group by 1 order by 1 -- This message was sent by Atlassian JIRA (v6.3.4#6332)