[jira] [Updated] (HIVE-1218) CREATE TABLE t LIKE some_view should create a new empty base table, but instead creates a copy of view

2011-07-13 Thread John Sichi (JIRA)

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

John Sichi updated HIVE-1218:
-

Status: Open  (was: Patch Available)

 CREATE TABLE t LIKE some_view should create a new empty base table, but 
 instead creates a copy of view
 --

 Key: HIVE-1218
 URL: https://issues.apache.org/jira/browse/HIVE-1218
 Project: Hive
  Issue Type: Bug
  Components: Metastore
Affects Versions: 0.5.0
Reporter: John Sichi
Assignee: Charles Chen
 Attachments: HIVE-1218v0.patch


 I think it should copy only the column definitions from the view metadata.  
 Currently it is copying the entire descriptor, resulting in a new view 
 instead of a new base table.

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




Review Request: Potential risk of resource leaks in Hive

2011-07-13 Thread chinnarao

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1098/
---

Review request for hive and John Sichi.


Summary
---

There are couple of resource leaks.
For example,
In CliDriver.java, Method :- processReader() the buffered reader is not closed.

Also there are risk(s) of resource(s) getting leaked , in such cases refactored 
the code to move closing of resources in finally block.


This addresses bug HIVE-1884.
https://issues.apache.org/jira/browse/HIVE-1884


Diffs
-

  trunk/cli/src/java/org/apache/hadoop/hive/cli/CliDriver.java 1145950 
  
trunk/contrib/src/java/org/apache/hadoop/hive/contrib/util/typedbytes/TypedBytesWritableInput.java
 1145950 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java 1145950 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/io/RCFileInputFormat.java 1145950 

Diff: https://reviews.apache.org/r/1098/diff


Testing
---

All unit tests passed


Thanks,

chinna



[jira] [Commented] (HIVE-1884) Potential risk of resource leaks in Hive

2011-07-13 Thread jirapos...@reviews.apache.org (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-1884?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064589#comment-13064589
 ] 

jirapos...@reviews.apache.org commented on HIVE-1884:
-


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1098/
---

Review request for hive and John Sichi.


Summary
---

There are couple of resource leaks.
For example,
In CliDriver.java, Method :- processReader() the buffered reader is not closed.

Also there are risk(s) of resource(s) getting leaked , in such cases refactored 
the code to move closing of resources in finally block.


This addresses bug HIVE-1884.
https://issues.apache.org/jira/browse/HIVE-1884


Diffs
-

  trunk/cli/src/java/org/apache/hadoop/hive/cli/CliDriver.java 1145950 
  
trunk/contrib/src/java/org/apache/hadoop/hive/contrib/util/typedbytes/TypedBytesWritableInput.java
 1145950 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java 1145950 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/io/RCFileInputFormat.java 1145950 

Diff: https://reviews.apache.org/r/1098/diff


Testing
---

All unit tests passed


Thanks,

chinna



 Potential risk of resource leaks in Hive
 

 Key: HIVE-1884
 URL: https://issues.apache.org/jira/browse/HIVE-1884
 Project: Hive
  Issue Type: Bug
  Components: CLI, Metastore, Query Processor, Server Infrastructure
Affects Versions: 0.3.0, 0.4.0, 0.4.1, 0.5.0, 0.6.0
 Environment: Hive 0.6.0, Hadoop 0.20.1
 SUSE Linux Enterprise Server 11 (i586)
Reporter: Mohit Sikri
Assignee: Chinna Rao Lalam
 Attachments: HIVE-1884.1.PATCH, HIVE-1884.2.patch, HIVE-1884.3.patch, 
 HIVE-1884.4.patch


 h3.There are couple of resource leaks.
 h4.For example,
 In CliDriver.java, Method :- processReader() the buffered reader is not 
 closed.
 h3.Also there are risk(s) of  resource(s) getting leaked , in such cases we 
 need to re factor the code to move closing of resources in finally block.
 h4. For Example :- 
 In Throttle.java   Method:- checkJobTracker() , the following code snippet 
 might cause resource leak.
 {code}
 InputStream in = url.openStream();
 in.read(buffer);
 in.close();
 {code}
 Ideally and as per the best coding practices it should be like below
 {code}
 InputStream in=null;
 try   {
 in = url.openStream();
 int numRead = in.read(buffer);
 }
 finally {
IOUtils.closeStream(in);
 }
 {code}
 Similar cases, were found in ExplainTask.java, DDLTask.java etc.Need to re 
 factor all such occurrences.

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




[jira] [Updated] (HIVE-2111) NullPointerException on select * with table using RegexSerDe and partitions

2011-07-13 Thread Chinna Rao Lalam (JIRA)

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

Chinna Rao Lalam updated HIVE-2111:
---

Attachment: HIVE-2111.2.patch

 NullPointerException on select * with table using RegexSerDe and partitions
 ---

 Key: HIVE-2111
 URL: https://issues.apache.org/jira/browse/HIVE-2111
 Project: Hive
  Issue Type: Bug
  Components: Serializers/Deserializers
Affects Versions: 0.7.0
 Environment: Amazon Elastic Mapreduce
Reporter: Marc Harris
Assignee: Chinna Rao Lalam
 Attachments: HIVE-2111.1.patch, HIVE-2111.2.patch, HIVE-2111.patch


 When querying against a table that is partitioned, and uses RegexSerde, 
 select with explicit columns works, but select * results in a 
 NullPointerException
 To reproduce:
 1) create a table containing the following text (notice the blank line):
 start
 fillerdatafillerdatafiller
 fillerdata2fillerdata2filler
 =end=
 2) copy the file to hdfs:
 hadoop dfs -put foo.txt test/part1=x/foo.txt
 3) run the following hive commands to create a table:
 add jar s3://elasticmapreduce/samples/hive/jars/hive_contrib.jar;
 drop table test;
 create external table test(col1 STRING, col2 STRING) 
 partitioned by (part1 STRING) 
 row format serde 'org.apache.hadoop.hive.contrib.serde2.RegexSerDe' 
 with serdeproperties ( input.regex = ^\(.*data\)\(.*data\).*$) 
 stored as textfile 
 location 'hdfs:///user/hadoop/test';
 alter table test add partition (part1='x');
 (Note that the text processor seems to have mangled the regex a bit. Inside 
 each pair of parentheses should be dot star data. After the second pair of 
 parentheses should be dot start dollar).
 4) select from it with explicit columns:
 select part1, col1, col2 from test;
 outputs:
 OK
 x fillerdata  fillerdata
 x NULLNULL
 x fillerdata  2fillerdata
 5) select from it with * columns
 select * from test;
 outputs:
 Failed with exception java.io.IOException:java.lang.NullPointerException
 11/04/12 14:28:27 ERROR CliDriver: Failed with exception 
 java.io.IOException:java.lang.NullPointerException
 java.io.IOException: java.lang.NullPointerException
   at org.apache.hadoop.hive.ql.exec.FetchTask.fetch(FetchTask.java:149)
   at org.apache.hadoop.hive.ql.Driver.getResults(Driver.java:1039)
   at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:172)
   at 
 org.apache.hadoop.hive.cli.CliDriver.processLineInternal(CliDriver.java:228)
   at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:209)
   at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:398)
   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:156)
 Caused by: java.lang.NullPointerException
   at java.util.ArrayList.addAll(ArrayList.java:472)
   at 
 org.apache.hadoop.hive.serde2.objectinspector.UnionStructObjectInspector.getStructFieldsDataAsList(UnionStructObjectInspector.java:144)
   at 
 org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe.serialize(LazySimpleSerDe.java:357)
   at org.apache.hadoop.hive.ql.exec.FetchTask.fetch(FetchTask.java:141)
   ... 10 more

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




[jira] [Commented] (HIVE-2111) NullPointerException on select * with table using RegexSerDe and partitions

2011-07-13 Thread Chinna Rao Lalam (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2111?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064594#comment-13064594
 ] 

Chinna Rao Lalam commented on HIVE-2111:


All existing testcases passed in my environment. I have added one testcase for 
this scenario.

 NullPointerException on select * with table using RegexSerDe and partitions
 ---

 Key: HIVE-2111
 URL: https://issues.apache.org/jira/browse/HIVE-2111
 Project: Hive
  Issue Type: Bug
  Components: Serializers/Deserializers
Affects Versions: 0.7.0
 Environment: Amazon Elastic Mapreduce
Reporter: Marc Harris
Assignee: Chinna Rao Lalam
 Attachments: HIVE-2111.1.patch, HIVE-2111.2.patch, HIVE-2111.patch


 When querying against a table that is partitioned, and uses RegexSerde, 
 select with explicit columns works, but select * results in a 
 NullPointerException
 To reproduce:
 1) create a table containing the following text (notice the blank line):
 start
 fillerdatafillerdatafiller
 fillerdata2fillerdata2filler
 =end=
 2) copy the file to hdfs:
 hadoop dfs -put foo.txt test/part1=x/foo.txt
 3) run the following hive commands to create a table:
 add jar s3://elasticmapreduce/samples/hive/jars/hive_contrib.jar;
 drop table test;
 create external table test(col1 STRING, col2 STRING) 
 partitioned by (part1 STRING) 
 row format serde 'org.apache.hadoop.hive.contrib.serde2.RegexSerDe' 
 with serdeproperties ( input.regex = ^\(.*data\)\(.*data\).*$) 
 stored as textfile 
 location 'hdfs:///user/hadoop/test';
 alter table test add partition (part1='x');
 (Note that the text processor seems to have mangled the regex a bit. Inside 
 each pair of parentheses should be dot star data. After the second pair of 
 parentheses should be dot start dollar).
 4) select from it with explicit columns:
 select part1, col1, col2 from test;
 outputs:
 OK
 x fillerdata  fillerdata
 x NULLNULL
 x fillerdata  2fillerdata
 5) select from it with * columns
 select * from test;
 outputs:
 Failed with exception java.io.IOException:java.lang.NullPointerException
 11/04/12 14:28:27 ERROR CliDriver: Failed with exception 
 java.io.IOException:java.lang.NullPointerException
 java.io.IOException: java.lang.NullPointerException
   at org.apache.hadoop.hive.ql.exec.FetchTask.fetch(FetchTask.java:149)
   at org.apache.hadoop.hive.ql.Driver.getResults(Driver.java:1039)
   at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:172)
   at 
 org.apache.hadoop.hive.cli.CliDriver.processLineInternal(CliDriver.java:228)
   at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:209)
   at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:398)
   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:156)
 Caused by: java.lang.NullPointerException
   at java.util.ArrayList.addAll(ArrayList.java:472)
   at 
 org.apache.hadoop.hive.serde2.objectinspector.UnionStructObjectInspector.getStructFieldsDataAsList(UnionStructObjectInspector.java:144)
   at 
 org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe.serialize(LazySimpleSerDe.java:357)
   at org.apache.hadoop.hive.ql.exec.FetchTask.fetch(FetchTask.java:141)
   ... 10 more

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




[jira] [Updated] (HIVE-2281) Regression introduced from HIVE-2155

2011-07-13 Thread Ning Zhang (JIRA)

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

Ning Zhang updated HIVE-2281:
-

   Resolution: Fixed
Fix Version/s: 0.8.0
 Hadoop Flags: [Reviewed]
   Status: Resolved  (was: Patch Available)

Committed. Thanks Syed!

 Regression introduced from HIVE-2155
 

 Key: HIVE-2281
 URL: https://issues.apache.org/jira/browse/HIVE-2281
 Project: Hive
  Issue Type: Bug
Reporter: Syed S. Albiz
Assignee: Syed S. Albiz
 Fix For: 0.8.0

 Attachments: HIVE-2281.1.patch


 EXPLAIN SELECT key, count(1) FROM src; throws a null pointer exception due to 
 the operator stack not being checked prior to use for constructing the error 
 message, due to the change introduced in HIVE-2155 to improve error message 
 context tokens.

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




[jira] [Updated] (HIVE-1538) FilterOperator is applied twice with ppd on.

2011-07-13 Thread John Sichi (JIRA)

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

John Sichi updated HIVE-1538:
-

   Resolution: Fixed
Fix Version/s: 0.8.0
 Hadoop Flags: [Reviewed]
   Status: Resolved  (was: Patch Available)

Committed.  Thanks Amareshwari!


 FilterOperator is applied twice with ppd on.
 

 Key: HIVE-1538
 URL: https://issues.apache.org/jira/browse/HIVE-1538
 Project: Hive
  Issue Type: Bug
  Components: Query Processor
Reporter: Amareshwari Sriramadasu
Assignee: Amareshwari Sriramadasu
 Fix For: 0.8.0

 Attachments: patch-1538-1.txt, patch-1538-2.txt, patch-1538-3.txt, 
 patch-1538-4.txt, patch-1538.txt


 With hive.optimize.ppd set to true, FilterOperator is applied twice. And it 
 seems second operator is always filtering zero rows.

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




[jira] [Commented] (HIVE-2155) Improve error messages emitted during semantic analysis

2011-07-13 Thread Hudson (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2155?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064794#comment-13064794
 ] 

Hudson commented on HIVE-2155:
--

Integrated in Hive-trunk-h0.21 #824 (See 
[https://builds.apache.org/job/Hive-trunk-h0.21/824/])
HIVE-2281. Regression introduced from HIVE-2155 (Syed S. Albiz via Ning 
Zhang)

nzhang : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1146100
Files : 
* /hive/trunk/ql/src/test/results/clientnegative/nonkey_groupby.q.out
* /hive/trunk/ql/src/test/queries/clientnegative/nonkey_groupby.q
* 
/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/TypeCheckProcFactory.java


 Improve error messages emitted during semantic analysis
 ---

 Key: HIVE-2155
 URL: https://issues.apache.org/jira/browse/HIVE-2155
 Project: Hive
  Issue Type: Improvement
Reporter: Syed S. Albiz
Assignee: Syed S. Albiz
 Fix For: 0.8.0

 Attachments: HIVE-2155.1.patch, HIVE-2155.2.patch, HIVE-2155.3.patch, 
 HIVE-2155.4.patch, HIVE-2155.5.patch


 Follow-up to HIVE-1731.
 A number of issues raised in HIVE-1731 were caused by SemanticAnalyzer not 
 reporting errors correctly.
 Specifically, the following issues need to be addressed:
 - Line numbers are not always provided and sometimes emitted as (0:-1), which 
 is useless
 - Insufficient or unclear context strings are provided
 Specific issues described in HIVE-1731:
 FAILED: Error in semantic analysis: Schema of both sides of union should 
 match: destinationid:_col1 _col2
 * No line/col numbers, context strings provide internal aliases instead of 
 actual column names
 FAILED: Error in semantic analysis: line 0:-1 Both Left and Right Aliases 
 Encountered in Join time
 * Incorrect line/col number info, no context strings to describe the aliases 
 encountered
 FAILED: Error in semantic analysis: AS clause has an invalid number of aliases
 * No line/col numbers, not context string to show the aliases encountered
 FAILED: Error in semantic analysis: line 1:94 Expression Not In Group By Key a
 * testcase: SELECT a.id, VAR(a.cnt) FROM mytable a
 * Context string is unhelpful, needs to provide the actual expression, not 
 just the table reference

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




[jira] [Commented] (HIVE-2281) Regression introduced from HIVE-2155

2011-07-13 Thread Hudson (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2281?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064795#comment-13064795
 ] 

Hudson commented on HIVE-2281:
--

Integrated in Hive-trunk-h0.21 #824 (See 
[https://builds.apache.org/job/Hive-trunk-h0.21/824/])
HIVE-2281. Regression introduced from HIVE-2155 (Syed S. Albiz via Ning 
Zhang)

nzhang : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1146100
Files : 
* /hive/trunk/ql/src/test/results/clientnegative/nonkey_groupby.q.out
* /hive/trunk/ql/src/test/queries/clientnegative/nonkey_groupby.q
* 
/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/TypeCheckProcFactory.java


 Regression introduced from HIVE-2155
 

 Key: HIVE-2281
 URL: https://issues.apache.org/jira/browse/HIVE-2281
 Project: Hive
  Issue Type: Bug
Reporter: Syed S. Albiz
Assignee: Syed S. Albiz
 Fix For: 0.8.0

 Attachments: HIVE-2281.1.patch


 EXPLAIN SELECT key, count(1) FROM src; throws a null pointer exception due to 
 the operator stack not being checked prior to use for constructing the error 
 message, due to the change introduced in HIVE-2155 to improve error message 
 context tokens.

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




Build failed in Jenkins: Hive-trunk-h0.21 #824

2011-07-13 Thread Apache Jenkins Server
See https://builds.apache.org/job/Hive-trunk-h0.21/824/changes

Changes:

[nzhang] HIVE-2281. Regression introduced from HIVE-2155 (Syed S. Albiz via 
Ning Zhang)

--
[...truncated 33249 lines...]
[artifact:deploy] Uploading: 
org/apache/hive/hive-hbase-handler/0.8.0-SNAPSHOT/hive-hbase-handler-0.8.0-20110713.192953-31.jar
 to repository apache.snapshots.https at 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] Transferring 49K from apache.snapshots.https
[artifact:deploy] Uploaded 49K
[artifact:deploy] [INFO] Uploading project information for hive-hbase-handler 
0.8.0-20110713.192953-31
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'snapshot 
org.apache.hive:hive-hbase-handler:0.8.0-SNAPSHOT'
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'artifact 
org.apache.hive:hive-hbase-handler'

ivy-init-dirs:

ivy-download:
  [get] Getting: 
http://repo2.maven.org/maven2/org/apache/ivy/ivy/2.1.0/ivy-2.1.0.jar
  [get] To: 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/build/ivy/lib/ivy-2.1.0.jar
  [get] Not modified - so not downloaded

ivy-probe-antlib:

ivy-init-antlib:

ivy-init:

ivy-resolve-maven-ant-tasks:
[ivy:resolve] :: loading settings :: file = 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/ivy/ivysettings.xml

ivy-retrieve-maven-ant-tasks:
[ivy:cachepath] DEPRECATED: 'ivy.conf.file' is deprecated, use 
'ivy.settings.file' instead
[ivy:cachepath] :: loading settings :: file = 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/ivy/ivysettings.xml

mvn-taskdef:

maven-publish-artifact:
[artifact:install-provider] Installing provider: 
org.apache.maven.wagon:wagon-http:jar:1.0-beta-2:runtime
[artifact:deploy] Deploying to 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] [INFO] Retrieving previous build number from 
apache.snapshots.https
[artifact:deploy] Uploading: 
org/apache/hive/hive-hwi/0.8.0-SNAPSHOT/hive-hwi-0.8.0-20110713.192954-31.jar 
to repository apache.snapshots.https at 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] Transferring 23K from apache.snapshots.https
[artifact:deploy] Uploaded 23K
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'snapshot 
org.apache.hive:hive-hwi:0.8.0-SNAPSHOT'
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'artifact 
org.apache.hive:hive-hwi'
[artifact:deploy] [INFO] Uploading project information for hive-hwi 
0.8.0-20110713.192954-31

ivy-init-dirs:

ivy-download:
  [get] Getting: 
http://repo2.maven.org/maven2/org/apache/ivy/ivy/2.1.0/ivy-2.1.0.jar
  [get] To: 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/build/ivy/lib/ivy-2.1.0.jar
  [get] Not modified - so not downloaded

ivy-probe-antlib:

ivy-init-antlib:

ivy-init:

ivy-resolve-maven-ant-tasks:
[ivy:resolve] :: loading settings :: file = 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/ivy/ivysettings.xml

ivy-retrieve-maven-ant-tasks:
[ivy:cachepath] DEPRECATED: 'ivy.conf.file' is deprecated, use 
'ivy.settings.file' instead
[ivy:cachepath] :: loading settings :: file = 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/ivy/ivysettings.xml

mvn-taskdef:

maven-publish-artifact:
[artifact:install-provider] Installing provider: 
org.apache.maven.wagon:wagon-http:jar:1.0-beta-2:runtime
[artifact:deploy] Deploying to 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] [INFO] Retrieving previous build number from 
apache.snapshots.https
[artifact:deploy] Uploading: 
org/apache/hive/hive-jdbc/0.8.0-SNAPSHOT/hive-jdbc-0.8.0-20110713.192956-31.jar 
to repository apache.snapshots.https at 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] Transferring 56K from apache.snapshots.https
[artifact:deploy] Uploaded 56K
[artifact:deploy] [INFO] Uploading project information for hive-jdbc 
0.8.0-20110713.192956-31
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'snapshot 
org.apache.hive:hive-jdbc:0.8.0-SNAPSHOT'
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'artifact 
org.apache.hive:hive-jdbc'

ivy-init-dirs:

ivy-download:
  [get] Getting: 
http://repo2.maven.org/maven2/org/apache/ivy/ivy/2.1.0/ivy-2.1.0.jar
  [get] To: 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/build/ivy/lib/ivy-2.1.0.jar
  [get] Not modified - so not downloaded

ivy-probe-antlib:


[jira] [Assigned] (HIVE-2247) ALTER TABLE RENAME PARTITION

2011-07-13 Thread Siying Dong (JIRA)

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

Siying Dong reassigned HIVE-2247:
-

Assignee: Weiyan Wang

 ALTER TABLE RENAME PARTITION
 

 Key: HIVE-2247
 URL: https://issues.apache.org/jira/browse/HIVE-2247
 Project: Hive
  Issue Type: New Feature
Reporter: Siying Dong
Assignee: Weiyan Wang

 We need a ALTER TABLE TABLE RENAME PARTITIONfunction that is similar t ALTER 
 TABLE RENAME.

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




[jira] [Updated] (HIVE-192) Add TIMESTAMP column type for thrift dynamic_type

2011-07-13 Thread Franklin Hu (JIRA)

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

Franklin Hu updated HIVE-192:
-

Summary: Add TIMESTAMP column type for thrift dynamic_type  (was: Add 
TIMESTAMP column type)

 Add TIMESTAMP column type for thrift dynamic_type
 -

 Key: HIVE-192
 URL: https://issues.apache.org/jira/browse/HIVE-192
 Project: Hive
  Issue Type: New Feature
  Components: Query Processor
Reporter: Johan Oskarsson
Assignee: Shyam Sundar Sarkar
  Labels: SQL
 Attachments: Hive-192.patch.txt, TIMESTAMP_specification.txt, 
 create_2.q.txt


 create table something2 (test timestamp);
 ERROR: DDL specifying type timestamp which has not been defined
 java.lang.RuntimeException: specifying type timestamp which has not been 
 defined
   at 
 org.apache.hadoop.hive.serde2.dynamic_type.thrift_grammar.FieldType(thrift_grammar.java:1879)
   at 
 org.apache.hadoop.hive.serde2.dynamic_type.thrift_grammar.Field(thrift_grammar.java:1545)
   at 
 org.apache.hadoop.hive.serde2.dynamic_type.thrift_grammar.FieldList(thrift_grammar.java:1501)
   at 
 org.apache.hadoop.hive.serde2.dynamic_type.thrift_grammar.Struct(thrift_grammar.java:1171)
   at 
 org.apache.hadoop.hive.serde2.dynamic_type.thrift_grammar.TypeDefinition(thrift_grammar.java:497)
   at 
 org.apache.hadoop.hive.serde2.dynamic_type.thrift_grammar.Definition(thrift_grammar.java:439)
   at 
 org.apache.hadoop.hive.serde2.dynamic_type.thrift_grammar.Start(thrift_grammar.java:101)
   at 
 org.apache.hadoop.hive.serde2.dynamic_type.DynamicSerDe.initialize(DynamicSerDe.java:97)
   at 
 org.apache.hadoop.hive.metastore.MetaStoreUtils.getDeserializer(MetaStoreUtils.java:180)
   at org.apache.hadoop.hive.ql.metadata.Table.initSerDe(Table.java:141)
   at org.apache.hadoop.hive.ql.metadata.Hive.createTable(Hive.java:202)
   at org.apache.hadoop.hive.ql.exec.DDLTask.createTable(DDLTask.java:641)
   at org.apache.hadoop.hive.ql.exec.DDLTask.execute(DDLTask.java:98)
   at org.apache.hadoop.hive.ql.Driver.run(Driver.java:215)
   at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:174)
   at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:207)
   at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:305)

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




[jira] [Commented] (HIVE-2260) ExecDriver::addInputPaths should pass the table properties to the record writer

2011-07-13 Thread Jakob Homan (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2260?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064916#comment-13064916
 ] 

Jakob Homan commented on HIVE-2260:
---

resonding to RB comment.
bq. Is it possible to add a testcase? If not, can you update the jira how it is 
tested?
Adding a testcase isn't possible without something like Mockito, since this is 
buried deep within the guts of a private method that calls many methods and 
creates new instances of classes from calls to getClass().  Even then it would 
take about a dozen mocks and be amazingly fragile.  This code is certainly ripe 
for refactoring to ease testing.

This was manually tested (and deployed to our cluster).  The manual test is to 
prune on a non-existent partition while using an input format like Haivvreo's, 
which makes use of the Properties instance.  Without the patch, the call fails. 
 With the patch, it succeeds with the behavior as described in 
{{ExecDriver.java}}:
{code:title=ExecDriver}// If the query references non-existent partitions
// We need to add a empty file, it is not acceptable to change the
// operator tree
// Consider the query:
// select * from (select count(1) from T union all select count(1) from
// T2) x;
// If T is empty and T2 contains 100 rows, the user expects: 0, 100 (2
// rows){code} 

 ExecDriver::addInputPaths should pass the table properties to the record 
 writer
 ---

 Key: HIVE-2260
 URL: https://issues.apache.org/jira/browse/HIVE-2260
 Project: Hive
  Issue Type: Bug
Affects Versions: 0.7.0
Reporter: Jakob Homan
Assignee: Jakob Homan
 Attachments: HIVE-2260.patch


 Currently when ExecDriver encounters a non-existent partition, it creates an 
 empty file so that the query will be valid (and return 0 results).  However, 
 when it does this and calls {{getHiveRecordWriter()}}, it creates a new 
 instance of Properties, rather than providing the Properties associated with 
 the table.
 This causes RecordWriters that pull information from the table through the 
 Properties to fail (such as [Haivvreo|http://bit.ly/iwEQzJ]).  The 
 RecordWriter should be provided the table's Properties, as it is in all other 
 cases where it's called.

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




[jira] [Created] (HIVE-2282) Local mode needs to work well with block sampling

2011-07-13 Thread Siying Dong (JIRA)
Local mode needs to work well with block sampling
-

 Key: HIVE-2282
 URL: https://issues.apache.org/jira/browse/HIVE-2282
 Project: Hive
  Issue Type: Improvement
Reporter: Siying Dong


Currently, if block sampling is enabled and large set of data are sampled to a 
small set, local mode needs to be kicked in. 

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




Build failed in Jenkins: Hive-trunk-h0.21 #825

2011-07-13 Thread Apache Jenkins Server
See https://builds.apache.org/job/Hive-trunk-h0.21/825/changes

Changes:

[jvs] HIVE-1538. FilterOperator is applied twice with ppd on.
(Amareshwari Sriramadasu via jvs)

--
[...truncated 33246 lines...]
[artifact:deploy] [INFO] Retrieving previous build number from 
apache.snapshots.https
[artifact:deploy] Uploading: 
org/apache/hive/hive-hbase-handler/0.8.0-SNAPSHOT/hive-hbase-handler-0.8.0-20110713.225624-32.jar
 to repository apache.snapshots.https at 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] Transferring 49K from apache.snapshots.https
[artifact:deploy] Uploaded 49K
[artifact:deploy] [INFO] Uploading project information for hive-hbase-handler 
0.8.0-20110713.225624-32
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'snapshot 
org.apache.hive:hive-hbase-handler:0.8.0-SNAPSHOT'
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'artifact 
org.apache.hive:hive-hbase-handler'

ivy-init-dirs:

ivy-download:
  [get] Getting: 
http://repo2.maven.org/maven2/org/apache/ivy/ivy/2.1.0/ivy-2.1.0.jar
  [get] To: 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/build/ivy/lib/ivy-2.1.0.jar
  [get] Not modified - so not downloaded

ivy-probe-antlib:

ivy-init-antlib:

ivy-init:

ivy-resolve-maven-ant-tasks:
[ivy:resolve] :: loading settings :: file = 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/ivy/ivysettings.xml

ivy-retrieve-maven-ant-tasks:
[ivy:cachepath] DEPRECATED: 'ivy.conf.file' is deprecated, use 
'ivy.settings.file' instead
[ivy:cachepath] :: loading settings :: file = 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/ivy/ivysettings.xml

mvn-taskdef:

maven-publish-artifact:
[artifact:install-provider] Installing provider: 
org.apache.maven.wagon:wagon-http:jar:1.0-beta-2:runtime
[artifact:deploy] Deploying to 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] [INFO] Retrieving previous build number from 
apache.snapshots.https
[artifact:deploy] Uploading: 
org/apache/hive/hive-hwi/0.8.0-SNAPSHOT/hive-hwi-0.8.0-20110713.225625-32.jar 
to repository apache.snapshots.https at 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] Transferring 23K from apache.snapshots.https
[artifact:deploy] Uploaded 23K
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'snapshot 
org.apache.hive:hive-hwi:0.8.0-SNAPSHOT'
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'artifact 
org.apache.hive:hive-hwi'
[artifact:deploy] [INFO] Uploading project information for hive-hwi 
0.8.0-20110713.225625-32

ivy-init-dirs:

ivy-download:
  [get] Getting: 
http://repo2.maven.org/maven2/org/apache/ivy/ivy/2.1.0/ivy-2.1.0.jar
  [get] To: 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/build/ivy/lib/ivy-2.1.0.jar
  [get] Not modified - so not downloaded

ivy-probe-antlib:

ivy-init-antlib:

ivy-init:

ivy-resolve-maven-ant-tasks:
[ivy:resolve] :: loading settings :: file = 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/ivy/ivysettings.xml

ivy-retrieve-maven-ant-tasks:
[ivy:cachepath] DEPRECATED: 'ivy.conf.file' is deprecated, use 
'ivy.settings.file' instead
[ivy:cachepath] :: loading settings :: file = 
/x1/jenkins/jenkins-slave/workspace/Hive-trunk-h0.21/hive/ivy/ivysettings.xml

mvn-taskdef:

maven-publish-artifact:
[artifact:install-provider] Installing provider: 
org.apache.maven.wagon:wagon-http:jar:1.0-beta-2:runtime
[artifact:deploy] Deploying to 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] [INFO] Retrieving previous build number from 
apache.snapshots.https
[artifact:deploy] Uploading: 
org/apache/hive/hive-jdbc/0.8.0-SNAPSHOT/hive-jdbc-0.8.0-20110713.225627-32.jar 
to repository apache.snapshots.https at 
https://repository.apache.org/content/repositories/snapshots
[artifact:deploy] Transferring 56K from apache.snapshots.https
[artifact:deploy] Uploaded 56K
[artifact:deploy] [INFO] Uploading project information for hive-jdbc 
0.8.0-20110713.225627-32
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'snapshot 
org.apache.hive:hive-jdbc:0.8.0-SNAPSHOT'
[artifact:deploy] [INFO] Retrieving previous metadata from 
apache.snapshots.https
[artifact:deploy] [INFO] Uploading repository metadata for: 'artifact 
org.apache.hive:hive-jdbc'

ivy-init-dirs:

ivy-download:
  [get] Getting: 
http://repo2.maven.org/maven2/org/apache/ivy/ivy/2.1.0/ivy-2.1.0.jar
  [get] To: 

[jira] [Commented] (HIVE-1538) FilterOperator is applied twice with ppd on.

2011-07-13 Thread Hudson (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-1538?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064933#comment-13064933
 ] 

Hudson commented on HIVE-1538:
--

Integrated in Hive-trunk-h0.21 #825 (See 
[https://builds.apache.org/job/Hive-trunk-h0.21/825/])
HIVE-1538. FilterOperator is applied twice with ppd on.
(Amareshwari Sriramadasu via jvs)

jvs : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1146129
Files : 
* /hive/trunk/ql/src/test/results/clientpositive/smb_mapjoin_6.q.out
* /hive/trunk/ql/src/test/results/clientpositive/bucket3.q.out
* /hive/trunk/ql/src/test/results/clientpositive/sample6.q.out
* /hive/trunk/ql/src/test/results/clientpositive/nullgroup4.q.out
* /hive/trunk/ql/src/test/results/clientpositive/join9.q.out
* /hive/trunk/ql/src/test/queries/clientpositive/ppd1.q
* /hive/trunk/ql/src/test/results/clientpositive/router_join_ppr.q.out
* /hive/trunk/ql/src/test/results/clientpositive/load_dyn_part13.q.out
* /hive/trunk/ql/src/test/results/clientpositive/having.q.out
* 
/hive/trunk/ql/src/test/results/clientpositive/index_bitmap_auto_partitioned.q.out
* /hive/trunk/ql/src/test/results/clientpositive/auto_join13.q.out
* /hive/trunk/ql/src/test/queries/clientpositive/ppd_join2.q
* /hive/trunk/ql/src/test/results/clientpositive/join26.q.out
* /hive/trunk/ql/src/test/results/clientpositive/ppd_gby2.q.out
* /hive/trunk/ql/src/test/results/clientpositive/merge_dynamic_partition2.q.out
* /hive/trunk/ql/src/test/results/clientpositive/input9.q.out
* /hive/trunk/ql/src/test/results/clientpositive/split_sample.q.out
* /hive/trunk/ql/src/test/results/compiler/plan/udf1.q.xml
* /hive/trunk/ql/src/test/results/clientpositive/transform_ppr1.q.out
* /hive/trunk/ql/src/test/results/clientpositive/notable_alias1.q.out
* /hive/trunk/ql/src/test/results/compiler/plan/join5.q.xml
* /hive/trunk/ql/src/test/results/clientpositive/input11_limit.q.out
* /hive/trunk/ql/src/test/results/compiler/plan/sample7.q.xml
* /hive/trunk/ql/src/test/results/compiler/plan/groupby6.q.xml
* /hive/trunk/ql/src/test/results/clientpositive/udf_10_trims.q.out
* /hive/trunk/ql/src/test/results/clientpositive/ppd_outer_join4.q.out
* 
/hive/trunk/ql/src/test/results/clientpositive/groupby_map_ppr_multi_distinct.q.out
* /hive/trunk/ql/src/test/results/clientpositive/udf_second.q.out
* /hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/ppd/ExprWalkerInfo.java
* /hive/trunk/ql/src/test/results/compiler/plan/input7.q.xml
* /hive/trunk/ql/src/test/results/clientpositive/index_auto_unused.q.out
* /hive/trunk/ql/src/test/results/clientpositive/udf_size.q.out
* /hive/trunk/ql/src/test/results/clientpositive/join12.q.out
* /hive/trunk/ql/src/test/queries/clientpositive/ppd_transform.q
* /hive/trunk/ql/src/test/results/clientpositive/lateral_view_ppd.q.out
* /hive/trunk/ql/src/test/results/clientpositive/sample3.q.out
* /hive/trunk/ql/src/test/results/clientpositive/join6.q.out
* /hive/trunk/ql/src/test/results/clientpositive/input26.q.out
* /hive/trunk/ql/src/test/results/clientpositive/load_dyn_part10.q.out
* /hive/trunk/ql/src/test/results/clientpositive/cast1.q.out
* /hive/trunk/ql/src/test/queries/clientpositive/ppd_gby.q
* /hive/trunk/ql/src/test/results/clientpositive/input2_limit.q.out
* /hive/trunk/ql/src/test/results/clientpositive/filter_join_breaktask.q.out
* /hive/trunk/ql/src/test/results/clientpositive/join40.q.out
* /hive/trunk/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java
* /hive/trunk/ql/src/test/results/compiler/plan/case_sensitivity.q.xml
* /hive/trunk/ql/src/test/results/clientpositive/join23.q.out
* /hive/trunk/ql/src/test/results/clientpositive/input6.q.out
* /hive/trunk/ql/src/test/results/clientpositive/pcr.q.out
* /hive/trunk/ql/src/test/results/clientpositive/subq2.q.out
* /hive/trunk/ql/src/test/results/compiler/plan/join2.q.xml
* /hive/trunk/hbase-handler/src/test/results/hbase_queries.q.out
* /hive/trunk/ql/src/test/results/compiler/plan/sample4.q.xml
* /hive/trunk/ql/src/test/results/compiler/plan/groupby3.q.xml
* /hive/trunk/ql/src/test/results/clientpositive/auto_join0.q.out
* /hive/trunk/ql/src/test/results/clientpositive/ppd_outer_join1.q.out
* /hive/trunk/ql/src/test/results/compiler/plan/udf6.q.xml
* /hive/trunk/ql/src/test/results/clientpositive/join_map_ppr.q.out
* /hive/trunk/ql/src/test/results/clientpositive/merge3.q.out
* /hive/trunk/ql/src/test/results/clientpositive/ppd_join2.q.out
* /hive/trunk/ql/src/test/results/clientpositive/input_part7.q.out
* /hive/trunk/ql/src/test/results/clientpositive/auto_join8.q.out
* /hive/trunk/hbase-handler/src/test/results/hbase_pushdown.q.out
* /hive/trunk/ql/src/test/results/clientpositive/index_auto_multiple.q.out
* /hive/trunk/ql/src/test/results/compiler/plan/input4.q.xml
* /hive/trunk/ql/src/test/results/clientpositive/load_dyn_part4.q.out
* /hive/trunk/ql/src/test/results/clientpositive/auto_join21.q.out
* 

[jira] [Commented] (HIVE-2272) add TIMESTAMP data type

2011-07-13 Thread Siying Dong (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2272?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064935#comment-13064935
 ] 

Siying Dong commented on HIVE-2272:
---

Can you add it to review board?

 add TIMESTAMP data type
 ---

 Key: HIVE-2272
 URL: https://issues.apache.org/jira/browse/HIVE-2272
 Project: Hive
  Issue Type: New Feature
Reporter: Franklin Hu
Assignee: Franklin Hu
 Attachments: hive-2272.1.patch, hive-2272.2.patch, hive-2272.3.patch


 Add TIMESTAMP type to serde2 that supports unix timestamp (1970-01-01 
 00:00:01 UTC to 2038-01-19 03:14:07 UTC) with optional nanosecond precision 
 using both LazyBinary and LazySimple SerDes. 
 For LazySimpleSerDe, the data is stored in jdbc compliant java.sql.Timestamp 
 parsable strings.

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




[jira] [Commented] (HIVE-2247) ALTER TABLE RENAME PARTITION

2011-07-13 Thread jirapos...@reviews.apache.org (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064937#comment-13064937
 ] 

jirapos...@reviews.apache.org commented on HIVE-2247:
-


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1105/
---

Review request for Siying Dong.


Summary
---

Implement ALTER TABLE PARTITION RENAME function to rename a partition. 
Add HiveQL syntax ALTER TABLE bar PARTITION (k1='v1', k2='v2') RENAME TO 
PARTITION (k1='v3', k2='v4');
This is my first Hive diff, I just learn everything from existing codebase and 
may not have a good understanding on it. 
Feel free to inform me if I make something wrong. Thanks


This addresses bug HIVE-2247.
https://issues.apache.org/jira/browse/HIVE-2247


Diffs
-

  trunk/metastore/src/gen/thrift/gen-php/hive_metastore/ThriftHiveMetastore.php 
1145366 
  
trunk/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp 
1145366 
  
trunk/metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ThriftHiveMetastore.java
 1145366 
  trunk/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp 1145366 
  trunk/metastore/if/hive_metastore.thrift 1145366 
  trunk/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h 1145366 
  trunk/metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb 1145366 
  trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java 
1145366 
  
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java
 1145366 
  
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java 
1145366 
  trunk/metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java 
1145366 
  trunk/metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java 
1145366 
  
trunk/metastore/src/test/org/apache/hadoop/hive/metastore/TestHiveMetaStore.java
 1145366 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java 1145366 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java 1145366 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java 
1145366 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g 1145366 
  
trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactory.java 
1145366 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/AlterTableDesc.java 1145366 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/DDLWork.java 1145366 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/HiveOperation.java 1145366 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/RenamePartitionDesc.java 
PRE-CREATION 
  trunk/ql/src/test/queries/clientnegative/alter_rename_partition_failure.q 
PRE-CREATION 
  trunk/ql/src/test/queries/clientnegative/alter_rename_partition_failure2.q 
PRE-CREATION 
  trunk/ql/src/test/queries/clientnegative/alter_rename_partition_failure3.q 
PRE-CREATION 
  trunk/ql/src/test/queries/clientpositive/alter_rename_partition.q 
PRE-CREATION 
  trunk/ql/src/test/results/clientnegative/alter_rename_partition_failure.q.out 
PRE-CREATION 
  
trunk/ql/src/test/results/clientnegative/alter_rename_partition_failure2.q.out 
PRE-CREATION 
  
trunk/ql/src/test/results/clientnegative/alter_rename_partition_failure3.q.out 
PRE-CREATION 
  trunk/ql/src/test/results/clientpositive/alter_rename_partition.q.out 
PRE-CREATION 
  
trunk/metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote 
1145366 
  trunk/metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py 
1145366 

Diff: https://reviews.apache.org/r/1105/diff


Testing
---

Add a partition A in the table
Rename partition A to partition B
Show the partitions in the table, it returns partition B.
SELECT the data from partition A, it returns no results
SELECT the data from partition B, it returns the data originally stored in 
partition A


Thanks,

Weiyan



 ALTER TABLE RENAME PARTITION
 

 Key: HIVE-2247
 URL: https://issues.apache.org/jira/browse/HIVE-2247
 Project: Hive
  Issue Type: New Feature
Reporter: Siying Dong
Assignee: Weiyan Wang

 We need a ALTER TABLE TABLE RENAME PARTITIONfunction that is similar t ALTER 
 TABLE RENAME.

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




[jira] [Updated] (HIVE-2247) ALTER TABLE RENAME PARTITION

2011-07-13 Thread Weiyan Wang (JIRA)

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

Weiyan Wang updated HIVE-2247:
--

Attachment: HIVE-2247.3.patch.txt

Implement ALTER TABLE PARTITION RENAME function to rename a partition. 
Add HiveQL syntax ALTER TABLE bar PARTITION (k1='v1', k2='v2') RENAME TO 
PARTITION (k1='v3', k2='v4');
This is my first Hive diff, I just learn everything from existing codebase and 
may not have a good understanding on it. 
Feel free to inform me if I make something wrong. Thanks

 ALTER TABLE RENAME PARTITION
 

 Key: HIVE-2247
 URL: https://issues.apache.org/jira/browse/HIVE-2247
 Project: Hive
  Issue Type: New Feature
Reporter: Siying Dong
Assignee: Weiyan Wang
 Attachments: HIVE-2247.3.patch.txt


 We need a ALTER TABLE TABLE RENAME PARTITIONfunction that is similar t ALTER 
 TABLE RENAME.

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




[jira] [Commented] (HIVE-1218) CREATE TABLE t LIKE some_view should create a new empty base table, but instead creates a copy of view

2011-07-13 Thread jirapos...@reviews.apache.org (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-1218?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064952#comment-13064952
 ] 

jirapos...@reviews.apache.org commented on HIVE-1218:
-


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1057/
---

(Updated 2011-07-13 23:34:26.247370)


Review request for hive.


Changes
---

Unit tests passed


Summary
---

https://issues.apache.org/jira/browse/HIVE-1218


This addresses bug HIVE-1218.
https://issues.apache.org/jira/browse/HIVE-1218


Diffs
-

  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java
 1145801 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java
 1145801 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/CreateTableLikeDesc.java
 1145801 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/test/queries/clientpositive/create_like.q
 1145801 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/test/results/clientpositive/create_like.q.out
 1145801 

Diff: https://reviews.apache.org/r/1057/diff


Testing (updated)
---

Unit tests passed


Thanks,

Charles



 CREATE TABLE t LIKE some_view should create a new empty base table, but 
 instead creates a copy of view
 --

 Key: HIVE-1218
 URL: https://issues.apache.org/jira/browse/HIVE-1218
 Project: Hive
  Issue Type: Bug
  Components: Metastore
Affects Versions: 0.5.0
Reporter: John Sichi
Assignee: Charles Chen
 Attachments: HIVE-1218v0.patch


 I think it should copy only the column definitions from the view metadata.  
 Currently it is copying the entire descriptor, resulting in a new view 
 instead of a new base table.

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




[jira] [Updated] (HIVE-1218) CREATE TABLE t LIKE some_view should create a new empty base table, but instead creates a copy of view

2011-07-13 Thread Charles Chen (JIRA)

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

Charles Chen updated HIVE-1218:
---

Attachment: HIVE-1218v2.patch

 CREATE TABLE t LIKE some_view should create a new empty base table, but 
 instead creates a copy of view
 --

 Key: HIVE-1218
 URL: https://issues.apache.org/jira/browse/HIVE-1218
 Project: Hive
  Issue Type: Bug
  Components: Metastore
Affects Versions: 0.5.0
Reporter: John Sichi
Assignee: Charles Chen
 Attachments: HIVE-1218v0.patch, HIVE-1218v2.patch


 I think it should copy only the column definitions from the view metadata.  
 Currently it is copying the entire descriptor, resulting in a new view 
 instead of a new base table.

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




[jira] [Updated] (HIVE-1218) CREATE TABLE t LIKE some_view should create a new empty base table, but instead creates a copy of view

2011-07-13 Thread Charles Chen (JIRA)

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

Charles Chen updated HIVE-1218:
---

Status: Patch Available  (was: Open)

 CREATE TABLE t LIKE some_view should create a new empty base table, but 
 instead creates a copy of view
 --

 Key: HIVE-1218
 URL: https://issues.apache.org/jira/browse/HIVE-1218
 Project: Hive
  Issue Type: Bug
  Components: Metastore
Affects Versions: 0.5.0
Reporter: John Sichi
Assignee: Charles Chen
 Attachments: HIVE-1218v0.patch, HIVE-1218v2.patch


 I think it should copy only the column definitions from the view metadata.  
 Currently it is copying the entire descriptor, resulting in a new view 
 instead of a new base table.

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




[jira] [Commented] (HIVE-2247) ALTER TABLE RENAME PARTITION

2011-07-13 Thread jirapos...@reviews.apache.org (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064966#comment-13064966
 ] 

jirapos...@reviews.apache.org commented on HIVE-2247:
-


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1105/#review1052
---



trunk/metastore/if/hive_metastore.thrift
https://reviews.apache.org/r/1105/#comment2131

Do we really need a new metastore function? Can we just use 
alter_partition()?



trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java
https://reviews.apache.org/r/1105/#comment2126

This doesn't seem to be correct to me. The partition should always have 
SerDe. Even if it doesn't have one, copying from the table's Serde doesn't seem 
to be the right thing to do.



trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java
https://reviews.apache.org/r/1105/#comment2127

Also, it doesn't seem to be correct to me here. There shouldn't be any case 
that we need to create new directory for the renamed partitions. Renaming 
should just change the name, with all other attributes kept.



trunk/metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java
https://reviews.apache.org/r/1105/#comment2128

I can't understand those codes. What you try to do here?



trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java
https://reviews.apache.org/r/1105/#comment2129

Since we only need old part spec and new part spec, why we make a new 
Partition object at all?



trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java
https://reviews.apache.org/r/1105/#comment2130

why we still continue when tab is null?



trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/HiveOperation.java
https://reviews.apache.org/r/1105/#comment2125

Privilege.ALTER_METADATA doesn't sound right to me here. Can you use 
Privilede.DROP and Priviledge.CREATE?



trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/RenamePartitionDesc.java
https://reviews.apache.org/r/1105/#comment2124

Looks like you copied from the file AddPartitionDesc, but do you need all 
those class members for renaming partition?


- Siying


On 2011-07-13 23:04:47, Weiyan Wang wrote:
bq.  
bq.  ---
bq.  This is an automatically generated e-mail. To reply, visit:
bq.  https://reviews.apache.org/r/1105/
bq.  ---
bq.  
bq.  (Updated 2011-07-13 23:04:47)
bq.  
bq.  
bq.  Review request for Siying Dong.
bq.  
bq.  
bq.  Summary
bq.  ---
bq.  
bq.  Implement ALTER TABLE PARTITION RENAME function to rename a partition. 
bq.  Add HiveQL syntax ALTER TABLE bar PARTITION (k1='v1', k2='v2') RENAME TO 
PARTITION (k1='v3', k2='v4');
bq.  This is my first Hive diff, I just learn everything from existing codebase 
and may not have a good understanding on it. 
bq.  Feel free to inform me if I make something wrong. Thanks
bq.  
bq.  
bq.  This addresses bug HIVE-2247.
bq.  https://issues.apache.org/jira/browse/HIVE-2247
bq.  
bq.  
bq.  Diffs
bq.  -
bq.  
bq.
trunk/metastore/src/gen/thrift/gen-php/hive_metastore/ThriftHiveMetastore.php 
1145366 
bq.
trunk/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp 
1145366 
bq.
trunk/metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ThriftHiveMetastore.java
 1145366 
bq.trunk/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp 1145366 
bq.trunk/metastore/if/hive_metastore.thrift 1145366 
bq.trunk/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h 1145366 
bq.trunk/metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb 1145366 
bq.
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java 
1145366 
bq.
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java
 1145366 
bq.
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java 
1145366 
bq.
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java 
1145366 
bq.trunk/metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java 
1145366 
bq.
trunk/metastore/src/test/org/apache/hadoop/hive/metastore/TestHiveMetaStore.java
 1145366 
bq.trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java 1145366 
bq.trunk/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java 1145366 
bq.
trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java 
1145366 
bq.trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g 1145366 
bq.
trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactory.java 
1145366 
bq.

Re: Review Request: HIVE-1078: CREATE VIEW followup: CREATE OR REPLACE

2011-07-13 Thread Charles Chen

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1058/
---

(Updated 2011-07-14 00:22:15.193620)


Review request for hive.


Changes
---

Rethrow original exceptions in createView to satisfy existing view tests.


Summary
---

https://issues.apache.org/jira/browse/HIVE-1078


This addresses bug HIVE-1078.
https://issues.apache.org/jira/browse/HIVE-1078


Diffs (updated)
-

  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/CreateViewDesc.java
 1146520 

Diff: https://reviews.apache.org/r/1058/diff


Testing
---

Unit tests written


Thanks,

Charles



[jira] [Commented] (HIVE-1078) CREATE VIEW followup: CREATE OR REPLACE

2011-07-13 Thread jirapos...@reviews.apache.org (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064976#comment-13064976
 ] 

jirapos...@reviews.apache.org commented on HIVE-1078:
-


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1058/
---

(Updated 2011-07-14 00:22:15.193620)


Review request for hive.


Changes
---

Rethrow original exceptions in createView to satisfy existing view tests.


Summary
---

https://issues.apache.org/jira/browse/HIVE-1078


This addresses bug HIVE-1078.
https://issues.apache.org/jira/browse/HIVE-1078


Diffs (updated)
-

  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/CreateViewDesc.java
 1146520 

Diff: https://reviews.apache.org/r/1058/diff


Testing
---

Unit tests written


Thanks,

Charles



 CREATE VIEW followup:  CREATE OR REPLACE
 

 Key: HIVE-1078
 URL: https://issues.apache.org/jira/browse/HIVE-1078
 Project: Hive
  Issue Type: Improvement
  Components: Query Processor
Affects Versions: 0.6.0
Reporter: John Sichi
Assignee: Charles Chen

 Currently, replacing a view requires
 DROP VIEW v;
 CREATE VIEW v AS new-definition;
 CREATE OR REPLACE would allow these to be combined into a single operation.

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




Re: Review Request: HIVE-1078: CREATE VIEW followup: CREATE OR REPLACE

2011-07-13 Thread Charles Chen

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1058/
---

(Updated 2011-07-14 00:45:22.036481)


Review request for hive.


Changes
---

Passes unit tests


Summary
---

https://issues.apache.org/jira/browse/HIVE-1078


This addresses bug HIVE-1078.
https://issues.apache.org/jira/browse/HIVE-1078


Diffs (updated)
-

  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/CreateViewDesc.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/test/results/clientpositive/create_view.q.out
 1146520 

Diff: https://reviews.apache.org/r/1058/diff


Testing (updated)
---

Passes unit tests


Thanks,

Charles



[jira] [Commented] (HIVE-1078) CREATE VIEW followup: CREATE OR REPLACE

2011-07-13 Thread jirapos...@reviews.apache.org (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064989#comment-13064989
 ] 

jirapos...@reviews.apache.org commented on HIVE-1078:
-


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1058/
---

(Updated 2011-07-14 00:45:22.036481)


Review request for hive.


Changes
---

Passes unit tests


Summary
---

https://issues.apache.org/jira/browse/HIVE-1078


This addresses bug HIVE-1078.
https://issues.apache.org/jira/browse/HIVE-1078


Diffs (updated)
-

  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/CreateViewDesc.java
 1146520 
  
http://svn.apache.org/repos/asf/hive/trunk/ql/src/test/results/clientpositive/create_view.q.out
 1146520 

Diff: https://reviews.apache.org/r/1058/diff


Testing (updated)
---

Passes unit tests


Thanks,

Charles



 CREATE VIEW followup:  CREATE OR REPLACE
 

 Key: HIVE-1078
 URL: https://issues.apache.org/jira/browse/HIVE-1078
 Project: Hive
  Issue Type: Improvement
  Components: Query Processor
Affects Versions: 0.6.0
Reporter: John Sichi
Assignee: Charles Chen
 Attachments: HIVE-1078v3.patch


 Currently, replacing a view requires
 DROP VIEW v;
 CREATE VIEW v AS new-definition;
 CREATE OR REPLACE would allow these to be combined into a single operation.

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




[jira] [Updated] (HIVE-1078) CREATE VIEW followup: CREATE OR REPLACE

2011-07-13 Thread Charles Chen (JIRA)

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

Charles Chen updated HIVE-1078:
---

Attachment: HIVE-1078v3.patch

 CREATE VIEW followup:  CREATE OR REPLACE
 

 Key: HIVE-1078
 URL: https://issues.apache.org/jira/browse/HIVE-1078
 Project: Hive
  Issue Type: Improvement
  Components: Query Processor
Affects Versions: 0.6.0
Reporter: John Sichi
Assignee: Charles Chen
 Attachments: HIVE-1078v3.patch


 Currently, replacing a view requires
 DROP VIEW v;
 CREATE VIEW v AS new-definition;
 CREATE OR REPLACE would allow these to be combined into a single operation.

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




[jira] [Updated] (HIVE-1078) CREATE VIEW followup: CREATE OR REPLACE

2011-07-13 Thread Charles Chen (JIRA)

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

Charles Chen updated HIVE-1078:
---

Status: Patch Available  (was: Open)

 CREATE VIEW followup:  CREATE OR REPLACE
 

 Key: HIVE-1078
 URL: https://issues.apache.org/jira/browse/HIVE-1078
 Project: Hive
  Issue Type: Improvement
  Components: Query Processor
Affects Versions: 0.6.0
Reporter: John Sichi
Assignee: Charles Chen
 Attachments: HIVE-1078v3.patch


 Currently, replacing a view requires
 DROP VIEW v;
 CREATE VIEW v AS new-definition;
 CREATE OR REPLACE would allow these to be combined into a single operation.

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




[jira] [Commented] (HIVE-2247) ALTER TABLE RENAME PARTITION

2011-07-13 Thread jirapos...@reviews.apache.org (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064993#comment-13064993
 ] 

jirapos...@reviews.apache.org commented on HIVE-2247:
-



bq.  On 2011-07-13 23:58:21, Siying Dong wrote:
bq.   
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java, 
line 1854
bq.   https://reviews.apache.org/r/1105/diff/1/?file=25067#file25067line1854
bq.  
bq.   Also, it doesn't seem to be correct to me here. There shouldn't be 
any case that we need to create new directory for the renamed partitions. 
Renaming should just change the name, with all other attributes kept.

In that case, what does physical data rename mean in the task if we are just 
supposed to change the name of partition?


- Weiyan


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1105/#review1052
---


On 2011-07-13 23:04:47, Weiyan Wang wrote:
bq.  
bq.  ---
bq.  This is an automatically generated e-mail. To reply, visit:
bq.  https://reviews.apache.org/r/1105/
bq.  ---
bq.  
bq.  (Updated 2011-07-13 23:04:47)
bq.  
bq.  
bq.  Review request for Siying Dong.
bq.  
bq.  
bq.  Summary
bq.  ---
bq.  
bq.  Implement ALTER TABLE PARTITION RENAME function to rename a partition. 
bq.  Add HiveQL syntax ALTER TABLE bar PARTITION (k1='v1', k2='v2') RENAME TO 
PARTITION (k1='v3', k2='v4');
bq.  This is my first Hive diff, I just learn everything from existing codebase 
and may not have a good understanding on it. 
bq.  Feel free to inform me if I make something wrong. Thanks
bq.  
bq.  
bq.  This addresses bug HIVE-2247.
bq.  https://issues.apache.org/jira/browse/HIVE-2247
bq.  
bq.  
bq.  Diffs
bq.  -
bq.  
bq.
trunk/metastore/src/gen/thrift/gen-php/hive_metastore/ThriftHiveMetastore.php 
1145366 
bq.
trunk/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp 
1145366 
bq.
trunk/metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ThriftHiveMetastore.java
 1145366 
bq.trunk/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp 1145366 
bq.trunk/metastore/if/hive_metastore.thrift 1145366 
bq.trunk/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h 1145366 
bq.trunk/metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb 1145366 
bq.
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java 
1145366 
bq.
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java
 1145366 
bq.
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java 
1145366 
bq.
trunk/metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java 
1145366 
bq.trunk/metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java 
1145366 
bq.
trunk/metastore/src/test/org/apache/hadoop/hive/metastore/TestHiveMetaStore.java
 1145366 
bq.trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java 1145366 
bq.trunk/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java 1145366 
bq.
trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java 
1145366 
bq.trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g 1145366 
bq.
trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactory.java 
1145366 
bq.trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/AlterTableDesc.java 
1145366 
bq.trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/DDLWork.java 1145366 
bq.trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/HiveOperation.java 
1145366 
bq.
trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/RenamePartitionDesc.java 
PRE-CREATION 
bq.
trunk/ql/src/test/queries/clientnegative/alter_rename_partition_failure.q 
PRE-CREATION 
bq.
trunk/ql/src/test/queries/clientnegative/alter_rename_partition_failure2.q 
PRE-CREATION 
bq.
trunk/ql/src/test/queries/clientnegative/alter_rename_partition_failure3.q 
PRE-CREATION 
bq.trunk/ql/src/test/queries/clientpositive/alter_rename_partition.q 
PRE-CREATION 
bq.
trunk/ql/src/test/results/clientnegative/alter_rename_partition_failure.q.out 
PRE-CREATION 
bq.
trunk/ql/src/test/results/clientnegative/alter_rename_partition_failure2.q.out 
PRE-CREATION 
bq.
trunk/ql/src/test/results/clientnegative/alter_rename_partition_failure3.q.out 
PRE-CREATION 
bq.trunk/ql/src/test/results/clientpositive/alter_rename_partition.q.out 
PRE-CREATION 
bq.
trunk/metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote 
1145366 
bq.
trunk/metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py 
1145366 
bq.  
bq.  Diff: 

[jira] [Commented] (HIVE-2247) ALTER TABLE RENAME PARTITION

2011-07-13 Thread Siying Dong (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13064994#comment-13064994
 ] 

Siying Dong commented on HIVE-2247:
---

Sorry for the confusion. I just meaned to change the directory name where the 
data is, and change the location parameter in the partition metadata.
If we decide not to change physical path, we just change partition name. If we 
need to change the physical path, then we need to change partition name and 
location.



 ALTER TABLE RENAME PARTITION
 

 Key: HIVE-2247
 URL: https://issues.apache.org/jira/browse/HIVE-2247
 Project: Hive
  Issue Type: New Feature
Reporter: Siying Dong
Assignee: Weiyan Wang
 Attachments: HIVE-2247.3.patch.txt


 We need a ALTER TABLE TABLE RENAME PARTITIONfunction that is similar t ALTER 
 TABLE RENAME.

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




[jira] [Updated] (HIVE-2204) unable to get column names for a specific table that has '_' as part of its table name

2011-07-13 Thread Patrick Hunt (JIRA)

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

Patrick Hunt updated HIVE-2204:
---

Attachment: HIVE-2204.patch

Added handling of escaped wildcard characters. Also updated jdbc tests to 
verify.

 unable to get column names for a specific table that has '_' as part of its 
 table name
 --

 Key: HIVE-2204
 URL: https://issues.apache.org/jira/browse/HIVE-2204
 Project: Hive
  Issue Type: Bug
  Components: JDBC
Affects Versions: 0.8.0
Reporter: Mythili Gopalakrishnan
Assignee: Patrick Hunt
 Attachments: HIVE-2204.patch


 I have a table age_group and I am trying to get list of columns for this 
 table name. As underscore and '%' have special meaning in table search 
 pattern according to JDBC searchPattern string specification, I escape the 
 '_' in my table name when I call getColumns for this single table. But HIVE 
 does not return any columns. My call to getColumns is as follows
 catalog   null
 schemaPattern %
 tableNamePattern  age\_group
 columnNamePattern  %
 If I don't escape the '_' in my tableNamePattern, I am able to get the list 
 of columns.

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




[jira] [Updated] (HIVE-2259) Skip comments in hive script

2011-07-13 Thread Carl Steinbach (JIRA)

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

Carl Steinbach updated HIVE-2259:
-

Component/s: CLI

 Skip comments in hive script
 

 Key: HIVE-2259
 URL: https://issues.apache.org/jira/browse/HIVE-2259
 Project: Hive
  Issue Type: Bug
  Components: CLI
Reporter: Vaibhav Aggarwal
Assignee: Vaibhav Aggarwal
 Attachments: HIVE-2259.patch


 If you specify something like:
 -- This is a comment
 add jar jar_path;
 select * from my_table;
 This fails.
 I have created a fix to skip the commented lines.

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




[jira] [Commented] (HIVE-2259) Skip comments in hive script

2011-07-13 Thread Carl Steinbach (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2259?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13065053#comment-13065053
 ] 

Carl Steinbach commented on HIVE-2259:
--

+1. Will commit if tests pass.

 Skip comments in hive script
 

 Key: HIVE-2259
 URL: https://issues.apache.org/jira/browse/HIVE-2259
 Project: Hive
  Issue Type: Bug
  Components: CLI
Reporter: Vaibhav Aggarwal
Assignee: Vaibhav Aggarwal
 Attachments: HIVE-2259.patch


 If you specify something like:
 -- This is a comment
 add jar jar_path;
 select * from my_table;
 This fails.
 I have created a fix to skip the commented lines.

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




Review Request: HIVE-2204 unable to get column names for a specific table that has '_' as part of its table name

2011-07-13 Thread Patrick Hunt

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1106/
---

Review request for hive and Carl Steinbach.


Summary
---

Added additional handling for escaped wildcards.


This addresses bug HIVE-2204.
https://issues.apache.org/jira/browse/HIVE-2204


Diffs
-

  jdbc/src/java/org/apache/hadoop/hive/jdbc/HiveDatabaseMetaData.java d1ff509 
  jdbc/src/test/org/apache/hadoop/hive/jdbc/TestJdbcDriver.java 591fa1f 

Diff: https://reviews.apache.org/r/1106/diff


Testing
---

added new tests, all tests pass for me.


Thanks,

Patrick



[jira] [Commented] (HIVE-2204) unable to get column names for a specific table that has '_' as part of its table name

2011-07-13 Thread jirapos...@reviews.apache.org (JIRA)

[ 
https://issues.apache.org/jira/browse/HIVE-2204?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13065055#comment-13065055
 ] 

jirapos...@reviews.apache.org commented on HIVE-2204:
-


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1106/
---

Review request for hive and Carl Steinbach.


Summary
---

Added additional handling for escaped wildcards.


This addresses bug HIVE-2204.
https://issues.apache.org/jira/browse/HIVE-2204


Diffs
-

  jdbc/src/java/org/apache/hadoop/hive/jdbc/HiveDatabaseMetaData.java d1ff509 
  jdbc/src/test/org/apache/hadoop/hive/jdbc/TestJdbcDriver.java 591fa1f 

Diff: https://reviews.apache.org/r/1106/diff


Testing
---

added new tests, all tests pass for me.


Thanks,

Patrick



 unable to get column names for a specific table that has '_' as part of its 
 table name
 --

 Key: HIVE-2204
 URL: https://issues.apache.org/jira/browse/HIVE-2204
 Project: Hive
  Issue Type: Bug
  Components: JDBC
Affects Versions: 0.8.0
Reporter: Mythili Gopalakrishnan
Assignee: Patrick Hunt
 Attachments: HIVE-2204.patch


 I have a table age_group and I am trying to get list of columns for this 
 table name. As underscore and '%' have special meaning in table search 
 pattern according to JDBC searchPattern string specification, I escape the 
 '_' in my table name when I call getColumns for this single table. But HIVE 
 does not return any columns. My call to getColumns is as follows
 catalog   null
 schemaPattern %
 tableNamePattern  age\_group
 columnNamePattern  %
 If I don't escape the '_' in my tableNamePattern, I am able to get the list 
 of columns.

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