[jira] Updated: (HIVE-474) Support for distinct selection on two or more columns

2010-03-29 Thread Mafish (JIRA)

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

Mafish updated HIVE-474:


Attachment: (was: hive-474.1.patch)

> Support for distinct selection on two or more columns
> -
>
> Key: HIVE-474
> URL: https://issues.apache.org/jira/browse/HIVE-474
> Project: Hadoop Hive
>  Issue Type: Improvement
>  Components: Query Processor
>Reporter: Alexis Rondeau
> Attachments: hive-474.0.4.2rc.patch
>
>
> The ability to select distinct several, individual columns as by example: 
> select count(distinct user), count(distinct session) from actions;   
> Currently returns the following failure: 
> FAILED: Error in semantic analysis: line 2:7 DISTINCT on Different Columns 
> not Supported user

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Updated: (HIVE-474) Support for distinct selection on two or more columns

2010-03-29 Thread Mafish (JIRA)

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

Mafish updated HIVE-474:


Attachment: hive-474.0.4.2rc.patch

for 0.4.2rc

> Support for distinct selection on two or more columns
> -
>
> Key: HIVE-474
> URL: https://issues.apache.org/jira/browse/HIVE-474
> Project: Hadoop Hive
>  Issue Type: Improvement
>  Components: Query Processor
>Reporter: Alexis Rondeau
> Attachments: hive-474.0.4.2rc.patch
>
>
> The ability to select distinct several, individual columns as by example: 
> select count(distinct user), count(distinct session) from actions;   
> Currently returns the following failure: 
> FAILED: Error in semantic analysis: line 2:7 DISTINCT on Different Columns 
> not Supported user

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Commented: (HIVE-474) Support for distinct selection on two or more columns

2010-03-29 Thread Mafish (JIRA)

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

Mafish commented on HIVE-474:
-

I have uploaded a patch originated from 0.4.2rc, please have a review.

> Support for distinct selection on two or more columns
> -
>
> Key: HIVE-474
> URL: https://issues.apache.org/jira/browse/HIVE-474
> Project: Hadoop Hive
>  Issue Type: Improvement
>  Components: Query Processor
>Reporter: Alexis Rondeau
> Attachments: hive-474.1.patch
>
>
> The ability to select distinct several, individual columns as by example: 
> select count(distinct user), count(distinct session) from actions;   
> Currently returns the following failure: 
> FAILED: Error in semantic analysis: line 2:7 DISTINCT on Different Columns 
> not Supported user

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Updated: (HIVE-474) Support for distinct selection on two or more columns

2010-03-29 Thread Mafish (JIRA)

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

Mafish updated HIVE-474:


Attachment: hive-474.1.patch

> Support for distinct selection on two or more columns
> -
>
> Key: HIVE-474
> URL: https://issues.apache.org/jira/browse/HIVE-474
> Project: Hadoop Hive
>  Issue Type: Improvement
>  Components: Query Processor
>Reporter: Alexis Rondeau
> Attachments: hive-474.1.patch
>
>
> The ability to select distinct several, individual columns as by example: 
> select count(distinct user), count(distinct session) from actions;   
> Currently returns the following failure: 
> FAILED: Error in semantic analysis: line 2:7 DISTINCT on Different Columns 
> not Supported user

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Commented: (HIVE-1202) "Unknown exception : null" while join

2010-03-01 Thread Mafish (JIRA)

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

Mafish commented on HIVE-1202:
--

@Zheng
With my patch, hive will omit the outmost where clauses while joining.
So it doesn't do partition pruning for this case, Which may be a problem in 
this situation.


> "Unknown exception : null" while join
> -
>
> Key: HIVE-1202
> URL: https://issues.apache.org/jira/browse/HIVE-1202
> Project: Hadoop Hive
>  Issue Type: Bug
>  Components: Query Processor
>Affects Versions: 0.4.1
> Environment: hive-0.4.1
> hadoop 0.19.1
>Reporter: Mafish
> Fix For: 0.4.1
>
> Attachments: HIVE-1202.branch-0.4.1.patch
>
>
> Hive throws "Unknown exception : null" with query:
> select * from 
> (
>   select name from classes 
> ) a
>   join classes b
> where a.name > b.number
> After tracing the code, I found this bug will occur with following
> conditions:
> 1. It is join operation.
> 2. At least one of the source of join is physical table (right side in
> above case).
> 3. With where condition and condition(s) of where clause must include
> columns from both side of join (a.name and b.number in case)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Commented: (HIVE-1202) "Unknown exception : null" while join

2010-03-01 Thread Mafish (JIRA)

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

Mafish commented on HIVE-1202:
--

@Yongqiang
We have a internal hive originate from  hive-0.4.2rc2. So we are not able to 
using the latest hive release.
This bug afftects 0.4.x only since hive-0.5.x uses a different pruning strategy.

I'm wondering if hive-0.4.x still need bug fixing since hive-0.5.x has been 
released?

> "Unknown exception : null" while join
> -
>
> Key: HIVE-1202
> URL: https://issues.apache.org/jira/browse/HIVE-1202
> Project: Hadoop Hive
>  Issue Type: Bug
>  Components: Query Processor
>Affects Versions: 0.4.1
> Environment: hive-0.4.1
> hadoop 0.19.1
>Reporter: Mafish
> Fix For: 0.4.1
>
> Attachments: HIVE-1202.branch-0.4.1.patch
>
>
> Hive throws "Unknown exception : null" with query:
> select * from 
> (
>   select name from classes 
> ) a
>   join classes b
> where a.name > b.number
> After tracing the code, I found this bug will occur with following
> conditions:
> 1. It is join operation.
> 2. At least one of the source of join is physical table (right side in
> above case).
> 3. With where condition and condition(s) of where clause must include
> columns from both side of join (a.name and b.number in case)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Commented: (HIVE-1202) "Unknown exception : null" while join

2010-02-28 Thread Mafish (JIRA)

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

Mafish commented on HIVE-1202:
--

Which trunk are you using?
I'm using release 0.4.1, which is checkoed out from 
http://svn.apache.org/repos/asf/hadoop/hive/branches/branch-0.4

$ svn info
Path: .
URL: http://svn.apache.org/repos/asf/hadoop/hive/branches/branch-0.4
Repository Root: http://svn.apache.org/repos/asf
Repository UUID: 13f79535-47bb-0310-9956-ffa450edef68
Revision: 916543
Node Kind: directory
Schedule: normal
Last Changed Author: nzhang
Last Changed Rev: 912061
Last Changed Date: 2010-02-20 09:44:44 +0800 (Sat, 20 Feb 2010)



> "Unknown exception : null" while join
> -
>
> Key: HIVE-1202
> URL: https://issues.apache.org/jira/browse/HIVE-1202
> Project: Hadoop Hive
>  Issue Type: Bug
>  Components: Query Processor
>Affects Versions: 0.4.1
> Environment: hive-0.4.1
> hadoop 0.19.1
>Reporter: Mafish
> Fix For: 0.4.1
>
> Attachments: HIVE-1202.branch-0.4.1.patch
>
>
> Hive throws "Unknown exception : null" with query:
> select * from 
> (
>   select name from classes 
> ) a
>   join classes b
> where a.name > b.number
> After tracing the code, I found this bug will occur with following
> conditions:
> 1. It is join operation.
> 2. At least one of the source of join is physical table (right side in
> above case).
> 3. With where condition and condition(s) of where clause must include
> columns from both side of join (a.name and b.number in case)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Commented: (HIVE-1202) "Unknown exception : null" while join

2010-02-28 Thread Mafish (JIRA)

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

Mafish commented on HIVE-1202:
--

Error message in hive is as title: Unknown exception : null.

And the call stack is the same as my first comment.

> "Unknown exception : null" while join
> -
>
> Key: HIVE-1202
> URL: https://issues.apache.org/jira/browse/HIVE-1202
> Project: Hadoop Hive
>  Issue Type: Bug
>  Components: Query Processor
>Affects Versions: 0.4.1
> Environment: hive-0.4.1
> hadoop 0.19.1
>Reporter: Mafish
> Fix For: 0.4.1
>
> Attachments: HIVE-1202.branch-0.4.1.patch
>
>
> Hive throws "Unknown exception : null" with query:
> select * from 
> (
>   select name from classes 
> ) a
>   join classes b
> where a.name > b.number
> After tracing the code, I found this bug will occur with following
> conditions:
> 1. It is join operation.
> 2. At least one of the source of join is physical table (right side in
> above case).
> 3. With where condition and condition(s) of where clause must include
> columns from both side of join (a.name and b.number in case)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Commented: (HIVE-1202) "Unknown exception : null" while join

2010-02-28 Thread Mafish (JIRA)

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

Mafish commented on HIVE-1202:
--

@Yongqaing
I ran the query:

select a.name, b.* from classes a join classes b on a.name = b.number where 
a.name > b.number 
It passed.

In this case, two tables are physical.

But when I changed one of them to sub-query, error occured again, as:

select a.name, b.* from  (select name from classes) a join classes b on a.name 
= b.number where a.name > b.number ;

Please try this case.

> "Unknown exception : null" while join
> -
>
> Key: HIVE-1202
> URL: https://issues.apache.org/jira/browse/HIVE-1202
> Project: Hadoop Hive
>  Issue Type: Bug
>  Components: Query Processor
>Affects Versions: 0.4.1
> Environment: hive-0.4.1
> hadoop 0.19.1
>Reporter: Mafish
> Fix For: 0.4.1
>
> Attachments: HIVE-1202.branch-0.4.1.patch
>
>
> Hive throws "Unknown exception : null" with query:
> select * from 
> (
>   select name from classes 
> ) a
>   join classes b
> where a.name > b.number
> After tracing the code, I found this bug will occur with following
> conditions:
> 1. It is join operation.
> 2. At least one of the source of join is physical table (right side in
> above case).
> 3. With where condition and condition(s) of where clause must include
> columns from both side of join (a.name and b.number in case)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Updated: (HIVE-1202) "Unknown exception : null" while join

2010-02-26 Thread Mafish (JIRA)

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

Mafish updated HIVE-1202:
-

Attachment: HIVE-1202.branch-0.4.1.patch

Attachment is the patch for this BUG.

It limits hive to perform pruning action only when the current query block 
contains only on table. 
This is fixed according to my understanding and I'm not sure it is the original 
idea of author. Author of the pruner is Yongqiang, right?

Please comment and evaluate it.

> "Unknown exception : null" while join
> -
>
> Key: HIVE-1202
> URL: https://issues.apache.org/jira/browse/HIVE-1202
> Project: Hadoop Hive
>  Issue Type: Bug
>  Components: Query Processor
>Affects Versions: 0.4.1
> Environment: hive-0.4.1
> hadoop 0.19.1
>Reporter: Mafish
> Fix For: 0.4.1
>
> Attachments: HIVE-1202.branch-0.4.1.patch
>
>
> Hive throws "Unknown exception : null" with query:
> select * from 
> (
>   select name from classes 
> ) a
>   join classes b
> where a.name > b.number
> After tracing the code, I found this bug will occur with following
> conditions:
> 1. It is join operation.
> 2. At least one of the source of join is physical table (right side in
> above case).
> 3. With where condition and condition(s) of where clause must include
> columns from both side of join (a.name and b.number in case)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Commented: (HIVE-1202) "Unknown exception : null" while join

2010-02-25 Thread Mafish (JIRA)

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

Mafish commented on HIVE-1202:
--

The call stack is:

org.apache.hadoop.hive.ql.session.SessionState$LogHelper.printError(SessionState.java:279)
 - FAILED: Unknown exception : null
java.lang.NullPointerException
at 
org.apache.hadoop.hive.ql.parse.QBMetaData.getTableForAlias(QBMetaData.java:76)
at 
org.apache.hadoop.hive.ql.parse.ASTPartitionPruner.getTableColumnDesc(ASTPartitionPruner.java:298)
at 
org.apache.hadoop.hive.ql.parse.ASTPartitionPruner.genExprNodeDesc(ASTPartitionPruner.java:220)
at 
org.apache.hadoop.hive.ql.parse.ASTPartitionPruner.genExprNodeDesc(ASTPartitionPruner.java:234)
at 
org.apache.hadoop.hive.ql.parse.ASTPartitionPruner.genExprNodeDesc(ASTPartitionPruner.java:234)
at 
org.apache.hadoop.hive.ql.parse.ASTPartitionPruner.addExpression(ASTPartitionPruner.java:397)
at 
org.apache.hadoop.hive.ql.parse.SemanticAnalyzer.genPartitionPruners(SemanticAnalyzer.java:624)
at 
org.apache.hadoop.hive.ql.parse.SemanticAnalyzer.analyzeInternal(SemanticAnalyzer.java:4440)
at 
org.apache.hadoop.hive.ql.parse.BaseSemanticAnalyzer.analyze(BaseSemanticAnalyzer.java:76)
at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:249)
at org.apache.hadoop.hive.ql.Driver.run(Driver.java:281)
at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:123)
at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:181)
at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:287)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.util.RunJar.main(RunJar.java:165)
at org.apache.hadoop.mapred.JobShell.run(JobShell.java:54)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:79)
at org.apache.hadoop.mapred.JobShell.main(JobShell.java:68)

This bug occurs while hive tries to prune table b, but it takes columns in 
where clauses. Bug there also exists columns of table a.  Thus, hive fails to 
find column "name" in table b.

> "Unknown exception : null" while join
> -
>
> Key: HIVE-1202
> URL: https://issues.apache.org/jira/browse/HIVE-1202
> Project: Hadoop Hive
>  Issue Type: Bug
>  Components: Query Processor
>Affects Versions: 0.4.1
> Environment: hive-0.4.1
> hadoop 0.19.1
>Reporter: Mafish
> Fix For: 0.4.1
>
>
> Hive throws "Unknown exception : null" with query:
> select * from 
> (
>   select name from classes 
> ) a
>   join classes b
> where a.name > b.number
> After tracing the code, I found this bug will occur with following
> conditions:
> 1. It is join operation.
> 2. At least one of the source of join is physical table (right side in
> above case).
> 3. With where condition and condition(s) of where clause must include
> columns from both side of join (a.name and b.number in case)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Created: (HIVE-1202) "Unknown exception : null" while join

2010-02-25 Thread Mafish (JIRA)
"Unknown exception : null" while join
-

 Key: HIVE-1202
 URL: https://issues.apache.org/jira/browse/HIVE-1202
 Project: Hadoop Hive
  Issue Type: Bug
  Components: Query Processor
Affects Versions: 0.4.1
 Environment: hive-0.4.1
hadoop 0.19.1
Reporter: Mafish
 Fix For: 0.4.1



Hive throws "Unknown exception : null" with query:

select * from 
(
  select name from classes 
) a
  join classes b
where a.name > b.number

After tracing the code, I found this bug will occur with following
conditions:
1. It is join operation.
2. At least one of the source of join is physical table (right side in
above case).
3. With where condition and condition(s) of where clause must include
columns from both side of join (a.name and b.number in case)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.