[
https://issues.apache.org/jira/browse/HIVE-238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14000078#comment-14000078
]
Steven Willis commented on HIVE-238:
------------------------------------
I'm coming from HIVE-4251 and I found that creating an index on a subfield
fails as well:
{noformat}
CREATE INDEX domainIndex
ON TABLE clicks(url.domain)
AS 'org.apache.hadoop.hive.ql.index.compact.CompactIndexHandler'
WITH DEFERRED REBUILD;
{noformat}
You get:
{noformat}
FAILED: ParseException line 2:19 mismatched input '.' expecting ) near 'url' in
create index statement
{noformat}
And there's no work-around that will work here. I think this also affects
{{CLUSTERED BY}}, {{SORTED BY}}, and {{SKEWED BY}} in the {{CREATE TABLE}}
statement. I wonder if this is just a parser issue rather than an actual
functionality issue.
> complex columns are not handled properly in cluster by, distributed by, sort
> by clauses and in some select clauses
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HIVE-238
> URL: https://issues.apache.org/jira/browse/HIVE-238
> Project: Hive
> Issue Type: New Feature
> Components: Query Processor
> Affects Versions: 0.3.0
> Reporter: Prasad Chakka
> Assignee: Ashish Thusoo
>
> if a column is complex then the sub fields can't be referenced in cluster by,
> distributed by, sort by clauses
> for example if column c1 is an object with attributes a and b then the
> following query returns an error
> select * from t1 cluster by t1.c1.a (or similar queries)
> also the following query will return an error because current code doesn't
> distinguish between a complex column or a table alias.
> select c1.a from t1
--
This message was sent by Atlassian JIRA
(v6.2#6252)