hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HIVE-1916) Change Default Alias For Aggregated Columns (_c1)
Date Tue, 16 Aug 2011 08:56:27 GMT

    [ https://issues.apache.org/jira/browse/HIVE-1916?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13085592#comment-13085592
] 

Hudson commented on HIVE-1916:
------------------------------

Integrated in Hive-trunk-h0.21 #898 (See [https://builds.apache.org/job/Hive-trunk-h0.21/898/])
    HIVE-1916. Change Default Alias For Aggregated Columns (_c1) (sameerm via nzhang)

nzhang : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1158104
Files : 
* /hive/trunk/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java
* /hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java
* /hive/trunk/ql/src/test/results/clientpositive/autogen_colalias.q.out
* /hive/trunk/ql/src/test/queries/clientpositive/autogen_colalias.q
* /hive/trunk/conf/hive-default.xml


> Change Default Alias For Aggregated Columns (_c1)
> -------------------------------------------------
>
>                 Key: HIVE-1916
>                 URL: https://issues.apache.org/jira/browse/HIVE-1916
>             Project: Hive
>          Issue Type: Improvement
>          Components: Query Processor
>         Environment: All
>            Reporter: James Mayfield
>            Assignee: Sameer M
>            Priority: Minor
>             Fix For: 0.8.0
>
>         Attachments: HIVE-1916.3.patch.txt
>
>
> Problem:
> When running a Hive query that aggregates (does a group by operation), Hive will automatically
name this column _c0, _c1, _c2, etc.. This is a problem because Hive will not then execute
a query against a column that begins with "_" and then the user has to manually input back-ticks
in order to get the query to run.
> Potential Solution:
> Hive should by default call these columns by their query assignment like "sum_active30day_users"
or if that is not possible, call it something simple like "column_1" so that users can then
query the new column without adding special back-ticks.
> Example Query:
> SELECT a.ds, COUNT(a.num_accounts)
> Example Result:
> ds, count_num_accounts OR ds, column_1

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message