hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carl Steinbach (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (HIVE-2228) Can't use DB qualified column names in WHERE or GROUP BY clauses
Date Mon, 20 Jun 2011 22:10:47 GMT

     [ https://issues.apache.org/jira/browse/HIVE-2228?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Carl Steinbach updated HIVE-2228:
---------------------------------

    Fix Version/s: 0.8.0

> Can't use DB qualified column names in WHERE or GROUP BY clauses
> ----------------------------------------------------------------
>
>                 Key: HIVE-2228
>                 URL: https://issues.apache.org/jira/browse/HIVE-2228
>             Project: Hive
>          Issue Type: Bug
>          Components: Query Processor
>    Affects Versions: 0.7.0
>            Reporter: Carl Steinbach
>             Fix For: 0.8.0
>
>
> Hive doesn't allow you to use DB qualified column names in the WHERE or GROUP BY clauses.
The workaround is to define a table alias:
> {noformat}
> hive> CREATE DATABASE db1;
> OK
> hive> CREATE TABLE db1.t(a INT, b INT);
> OK
> hive> SELECT * FROM db1.t WHERE db1.t.a > 100;
> FAILED: Error in semantic analysis: Line 1:26 Invalid table alias or column reference
'db1'
> hive> SELECT * FROM db1.t t WHERE t.a > 100;
> OK
> hive> SELECT * FROM db1.t GROUP BY db1.t.a;
> FAILED: Error in semantic analysis: Line 1:29 Invalid table alias or column reference
'db1'
> hive> SELECT * FROM db1.t t GROUP BY t.a;
> OK
> {noformat}

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

        

Mime
View raw message