[jira] [Commented] (HIVE-3304) sort merge join should work if both the tables are sorted in descending order

2012-08-05 Thread Namit Jain (JIRA)

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

Namit Jain commented on HIVE-3304:
--

fixed

 sort merge join should work if both the tables are sorted in descending order
 -

 Key: HIVE-3304
 URL: https://issues.apache.org/jira/browse/HIVE-3304
 Project: Hive
  Issue Type: New Feature
  Components: Query Processor
Reporter: Namit Jain
Assignee: Namit Jain
 Attachments: hive.3304.1.patch, hive.3304.2.patch, hive.3304.3.patch, 
 hive.3304.4.patch


 Currently, sort merge join only works if both the tables are sorted in
 ascending order

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Updated] (HIVE-3304) sort merge join should work if both the tables are sorted in descending order

2012-08-05 Thread Namit Jain (JIRA)

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

Namit Jain updated HIVE-3304:
-

Attachment: hive.3304.4.patch

 sort merge join should work if both the tables are sorted in descending order
 -

 Key: HIVE-3304
 URL: https://issues.apache.org/jira/browse/HIVE-3304
 Project: Hive
  Issue Type: New Feature
  Components: Query Processor
Reporter: Namit Jain
Assignee: Namit Jain
 Attachments: hive.3304.1.patch, hive.3304.2.patch, hive.3304.3.patch, 
 hive.3304.4.patch


 Currently, sort merge join only works if both the tables are sorted in
 ascending order

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HIVE-3304) sort merge join should work if both the tables are sorted in descending order

2012-08-05 Thread Kevin Wilfong (JIRA)

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

Kevin Wilfong commented on HIVE-3304:
-

Thanks, running tests again.

 sort merge join should work if both the tables are sorted in descending order
 -

 Key: HIVE-3304
 URL: https://issues.apache.org/jira/browse/HIVE-3304
 Project: Hive
  Issue Type: New Feature
  Components: Query Processor
Reporter: Namit Jain
Assignee: Namit Jain
 Attachments: hive.3304.1.patch, hive.3304.2.patch, hive.3304.3.patch, 
 hive.3304.4.patch


 Currently, sort merge join only works if both the tables are sorted in
 ascending order

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HIVE-3086) Skewed Join Optimization

2012-08-05 Thread Namit Jain (JIRA)

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

Namit Jain commented on HIVE-3086:
--

@Alex, The problem that you mentioned can be handled by 
https://issues.apache.org/jira/browse/HIVE-3286.

Navis is working on that. These are independent strategies and can be applied.

 Skewed Join Optimization
 

 Key: HIVE-3086
 URL: https://issues.apache.org/jira/browse/HIVE-3086
 Project: Hive
  Issue Type: New Feature
Reporter: Nadeem Moidu
Assignee: Nadeem Moidu

 During a join operation, if one of the columns has a skewed key, it can cause 
 that particular reducer to become the bottleneck. The following feature will 
 address it:
 https://cwiki.apache.org/confluence/display/Hive/Skewed+Join+Optimization

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




Build failed in Jenkins: Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false #97

2012-08-05 Thread Apache Jenkins Server
See 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/

--
[...truncated 10115 lines...]
 [echo] Project: odbc
 [copy] Warning: 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/ws/hive/odbc/src/conf
 does not exist.

ivy-resolve-test:
 [echo] Project: odbc

ivy-retrieve-test:
 [echo] Project: odbc

compile-test:
 [echo] Project: odbc

create-dirs:
 [echo] Project: serde
 [copy] Warning: 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/ws/hive/serde/src/test/resources
 does not exist.

init:
 [echo] Project: serde

ivy-init-settings:
 [echo] Project: serde

ivy-resolve:
 [echo] Project: serde
[ivy:resolve] :: loading settings :: file = 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/ws/hive/ivy/ivysettings.xml
[ivy:report] Processing 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/artifact/hive/build/ivy/resolution-cache/org.apache.hive-hive-serde-default.xml
 to 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/artifact/hive/build/ivy/report/org.apache.hive-hive-serde-default.html

ivy-retrieve:
 [echo] Project: serde

dynamic-serde:

compile:
 [echo] Project: serde

ivy-resolve-test:
 [echo] Project: serde

ivy-retrieve-test:
 [echo] Project: serde

compile-test:
 [echo] Project: serde
[javac] Compiling 26 source files to 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/artifact/hive/build/serde/test/classes
[javac] Note: Some input files use or override a deprecated API.
[javac] Note: Recompile with -Xlint:deprecation for details.
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.

create-dirs:
 [echo] Project: service
 [copy] Warning: 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/ws/hive/service/src/test/resources
 does not exist.

init:
 [echo] Project: service

ivy-init-settings:
 [echo] Project: service

ivy-resolve:
 [echo] Project: service
[ivy:resolve] :: loading settings :: file = 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/ws/hive/ivy/ivysettings.xml
[ivy:report] Processing 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/artifact/hive/build/ivy/resolution-cache/org.apache.hive-hive-service-default.xml
 to 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/artifact/hive/build/ivy/report/org.apache.hive-hive-service-default.html

ivy-retrieve:
 [echo] Project: service

compile:
 [echo] Project: service

ivy-resolve-test:
 [echo] Project: service

ivy-retrieve-test:
 [echo] Project: service

compile-test:
 [echo] Project: service
[javac] Compiling 2 source files to 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/artifact/hive/build/service/test/classes

test:
 [echo] Project: hive

test-shims:
 [echo] Project: hive

test-conditions:
 [echo] Project: shims

gen-test:
 [echo] Project: shims

create-dirs:
 [echo] Project: shims
 [copy] Warning: 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/ws/hive/shims/src/test/resources
 does not exist.

init:
 [echo] Project: shims

ivy-init-settings:
 [echo] Project: shims

ivy-resolve:
 [echo] Project: shims
[ivy:resolve] :: loading settings :: file = 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/ws/hive/ivy/ivysettings.xml
[ivy:report] Processing 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/artifact/hive/build/ivy/resolution-cache/org.apache.hive-hive-shims-default.xml
 to 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/artifact/hive/build/ivy/report/org.apache.hive-hive-shims-default.html

ivy-retrieve:
 [echo] Project: shims

compile:
 [echo] Project: shims
 [echo] Building shims 0.20

build_shims:
 [echo] Project: shims
 [echo] Compiling 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/ws/hive/shims/src/common/java;/home/jenkins/jenkins-slave/workspace/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/hive/shims/src/0.20/java
 against hadoop 0.20.2 
(https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/97/artifact/hive/build/hadoopcore/hadoop-0.20.2)

ivy-init-settings:
 [echo] Project: shims

ivy-resolve-hadoop-shim:
 [echo] Project: shims
[ivy:resolve] :: loading settings :: file = 
https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21-keepgoing=false/ws/hive/ivy/ivysettings.xml

ivy-retrieve-hadoop-shim:
 [echo] Project: shims
 [echo] Building shims 0.20S

build_shims:
 [echo] Project: shims
 [echo] Compiling 

Jenkins build is back to normal : Hive-0.9.1-SNAPSHOT-h0.21 #97

2012-08-05 Thread Apache Jenkins Server
See https://builds.apache.org/job/Hive-0.9.1-SNAPSHOT-h0.21/97/



Hive-trunk-h0.21 - Build # 1593 - Failure

2012-08-05 Thread Apache Jenkins Server
Changes for Build #1593



1 tests failed.
REGRESSION:  
org.apache.hadoop.hive.cli.TestNegativeCliDriver.testNegativeCliDriver_script_broken_pipe1

Error Message:
Unexpected exception See build/ql/tmp/hive.log, or try ant test ... 
-Dtest.silent=false to get more logs.

Stack Trace:
junit.framework.AssertionFailedError: Unexpected exception
See build/ql/tmp/hive.log, or try ant test ... -Dtest.silent=false to get 
more logs.
at junit.framework.Assert.fail(Assert.java:50)
at 
org.apache.hadoop.hive.cli.TestNegativeCliDriver.testNegativeCliDriver_script_broken_pipe1(TestNegativeCliDriver.java:10849)
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 junit.framework.TestCase.runTest(TestCase.java:168)
at junit.framework.TestCase.runBare(TestCase.java:134)
at junit.framework.TestResult$1.protect(TestResult.java:110)
at junit.framework.TestResult.runProtected(TestResult.java:128)
at junit.framework.TestResult.run(TestResult.java:113)
at junit.framework.TestCase.run(TestCase.java:124)
at junit.framework.TestSuite.runTest(TestSuite.java:243)
at junit.framework.TestSuite.run(TestSuite.java:238)
at 
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTestRunner.java:422)
at 
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.launch(JUnitTestRunner.java:931)
at 
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestRunner.java:785)




The Apache Jenkins build system has built Hive-trunk-h0.21 (build #1593)

Status: Failure

Check console output at https://builds.apache.org/job/Hive-trunk-h0.21/1593/ to 
view the results.

[jira] [Updated] (HIVE-2925) Support non-MR fetching for simple queries with select/limit/filter operations only

2012-08-05 Thread Navis (JIRA)

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

Navis updated HIVE-2925:


Status: Patch Available  (was: Open)

Passed all tests

 Support non-MR fetching for simple queries with select/limit/filter 
 operations only
 ---

 Key: HIVE-2925
 URL: https://issues.apache.org/jira/browse/HIVE-2925
 Project: Hive
  Issue Type: Improvement
Affects Versions: 0.10.0
Reporter: Navis
Assignee: Navis
Priority: Trivial
 Attachments: HIVE-2925.1.patch.txt, HIVE-2925.2.patch.txt, 
 HIVE-2925.D2607.1.patch, HIVE-2925.D2607.2.patch, HIVE-2925.D2607.3.patch, 
 HIVE-2925.D2607.4.patch


 It's trivial but frequently asked by end-users. Currently, select queries 
 with simple conditions or limit should run MR job which takes some time 
 especially for big tables, making the people irritated.
 For that kind of simple queries, using fetch task would make them happy.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Created] (HIVE-3335) Thousand of CLOSE_WAIT socket when we using SymbolicInputFormat

2012-08-05 Thread Show You (JIRA)
Show You created HIVE-3335:
--

 Summary: Thousand of CLOSE_WAIT socket when we using 
SymbolicInputFormat
 Key: HIVE-3335
 URL: https://issues.apache.org/jira/browse/HIVE-3335
 Project: Hive
  Issue Type: Bug
  Components: Clients
Affects Versions: 0.8.1
 Environment:  CentOS 5.8 x64
 CDH3u4
   hadoop-0.20-0.20.2+923.256-1
   
hadoop-0.20-{namenode,secondarynamenode,jobtracker,tasktracker,datanode}-0.20.2+923.256-1
   hadoop-0.20-conf-pseudo-0.20.2+923.256-1(but same error was
occurred on not pseudo env)
 apache hive-0.8.1(but same error was occurred on hive 0.9)
Reporter: Show You


Procedure for reproduction:
 1. Set up hadoop
 2. Prepare data file and link.txt:
data:
  $ hadoop fs -cat /path/to/data/2012-07-01/20120701.csv
  1, 20120701 00:00:00
  2, 20120701 00:00:01
  3, 20120701 01:12:45
link.txt
  $ cat link.txt
   /path/to/data/2012-07-01//*

 2. On hive, create table like below:
   CREATE TABLE user_logs(id INT, created_at STRING)
   row format delimited fields terminated by ',' lines terminated by '\n'
   stored as inputformat 'org.apache.hadoop.hive.ql.io.SymlinkTextInputFormat'
   outputformat 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat';

 3. Put link.txt to /user/hive/warehouse/user_logs
   $ sudo -u hdfs hadoop fs -put link.txt  /user/hive/warehouse/user_logs

 4. Open another session(A session), and watch socket,
   $ netstat -a | grep CLOSE_WAIT
tcp1  0 localhost:48121 localhost:50010
 CLOSE_WAIT
tcp1  0 localhost:48124 localhost:50010
 CLOSE_WAIT
   $

 5. Return to hive session, execute this,
   $ select * from user_logs;

 6. Return to A session, watch socket again,
   $ netstat -a | grep CLOSE_WAIT
   tcp1  0 localhost:48121 localhost:50010
CLOSE_WAIT
   tcp1  0 localhost:48124 localhost:50010
CLOSE_WAIT
   tcp1  0 localhost:48166 localhost:50010
CLOSE_WAIT

 If you makes any partitions, you'll watch unclosed socket whose count
equals partitions by once.


I think that this problem maybe is caused by this point:
  At 
https://github.com/apache/hive/blob/trunk/ql/src/java/org/apache/hadoop/hive/ql/io/SymbolicInputFormat.java,
  line 66. BufferedReader was opened, but it doesn't closed.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HIVE-2845) Add support for index joins in Hive

2012-08-05 Thread Mahsa Mofidpoor (JIRA)

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

Mahsa Mofidpoor commented on HIVE-2845:
---

I put my code in optimizer/physical, pretty much the same as how HIVE-1644 is 
organized.
I removed the TS from topToTable and opParseContext and also the table from 
topOps. Then I updated the correspondent operator and table(index table) in 
OpParseContext and ParseContext respectively, but the map logs shows the 
original table still being scanned.
1.Should I regenerate the operator tree afterwards? probably by using 
RewriteParseContextGenerator?
2.Is a new RowResolver needed?

 Add support for index joins in Hive
 ---

 Key: HIVE-2845
 URL: https://issues.apache.org/jira/browse/HIVE-2845
 Project: Hive
  Issue Type: New Feature
  Components: Indexing, Query Processor
Reporter: Namit Jain
  Labels: indexing, joins, performance

 Hive supports indexes, which are used for filters currently.
 It would be very useful to add support for index-based joins in Hive.
 If 2 tables A and B are being joined, and an index exists on the join key of 
 A,
 B can be scanned (by the mappers), and for each row in B, a lookup for the 
 corresponding row in A can be performed.
 This can be very useful for some usecases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HIVE-3299) UDF DAYNAME(date) to HIVE

2012-08-05 Thread Namitha Babychan (JIRA)

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

Namitha Babychan commented on HIVE-3299:


@Carl Steinbach : I have attached the patch for the issue. Please review and 
let me know if any modifications has to be made. Thanks.

 UDF  DAYNAME(date) to HIVE 
 ---

 Key: HIVE-3299
 URL: https://issues.apache.org/jira/browse/HIVE-3299
 Project: Hive
  Issue Type: New Feature
  Components: UDF
Affects Versions: 0.9.0
Reporter: Namitha Babychan
Assignee: Namitha Babychan
  Labels: patch
 Fix For: 0.10.0

 Attachments: HIVE-3299.1.patch.txt, Hive-3299_Testcase.doc, 
 hive-3299.1.patch


 Current releases of Hive lacks a function which would return the day name 
 corresponding to a date / timestamp value which might be a part of a column.  
  
 The function -DAYNAME (date) would return the day name from a date / 
 timestamp or column which would be useful while using HiveQL. This would find 
 its use  in various business sectors like retail, which would help in  
 identifying the trends and sales datails for a particular weekday for entire 
 year,month or week.
 Functionality :-
 Function Name: DAYNAME (date)

 Returns the name of the weekday for date. 
 Example: hive SELECT DAYNAME('2012-07-25');
- 'Wednesday'
 Usage :-
 Case 1 : To find DAY NAME corresponding to a particular date 
 hive SELECT DAYNAME('2012-07-25');
- 'Wednesday'
 Case 2 : To query a table to find details based on a particular day name
 Table :-
 date  |item id|store id|value|unit|price
 01/07/2012|110001|00003|0.99|1.00|0.99
 02/07/2012|110001|00008|0.99|0.00|0.00
 03/07/2012|110001|00009|0.99|0.00|0.00
 04/07/2012|110001|001112002|0.99|0.00|0.00
 05/07/2012|110001|001112003|0.99|0.00|0.00
 06/07/2012|110001|001112006|0.99|1.00|0.99
 07/07/2012|110001|001112007|0.99|0.00|0.00
 08/07/2012|110001|001112008|0.99|0.00|0.00
 09/07/2012|110001|001112009|0.99|0.00|0.00
 10/07/2012|110001|001112010|0.99|0.00|0.00
 11/07/2012|110001|001113003|0.99|0.00|0.00
 12/07/2012|110001|001113006|0.99|0.00|0.00
 13/07/2012|110001|001113008|0.99|0.00|0.00
 14/07/2012|110001|001113010|0.99|0.00|0.00
 15/07/2012|110001|001114002|0.99|0.00|0.00
 16/07/2012|110001|001114004|0.99|1.00|0.99
 17/07/2012|110001|001114005|0.99|0.00|0.00
 18/07/2012|110001|001121004|0.99|0.00|0.00
 Query : select * from sales where dayname(date)='wednesday';
 Result :-
 04/07/2012|110001|001112002|0.99|0.00|0.00
 11/07/2012|110001|001113003|0.99|0.00|0.00
 18/07/2012|110001|001121004|0.99|0.00|0.00

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Assigned] (HIVE-3299) UDF DAYNAME(date) to HIVE

2012-08-05 Thread Namitha Babychan (JIRA)

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

Namitha Babychan reassigned HIVE-3299:
--

Assignee: (was: Namitha Babychan)

 UDF  DAYNAME(date) to HIVE 
 ---

 Key: HIVE-3299
 URL: https://issues.apache.org/jira/browse/HIVE-3299
 Project: Hive
  Issue Type: New Feature
  Components: UDF
Affects Versions: 0.9.0
Reporter: Namitha Babychan
  Labels: patch
 Fix For: 0.10.0

 Attachments: HIVE-3299.1.patch.txt, Hive-3299_Testcase.doc, 
 hive-3299.1.patch


 Current releases of Hive lacks a function which would return the day name 
 corresponding to a date / timestamp value which might be a part of a column.  
  
 The function -DAYNAME (date) would return the day name from a date / 
 timestamp or column which would be useful while using HiveQL. This would find 
 its use  in various business sectors like retail, which would help in  
 identifying the trends and sales datails for a particular weekday for entire 
 year,month or week.
 Functionality :-
 Function Name: DAYNAME (date)

 Returns the name of the weekday for date. 
 Example: hive SELECT DAYNAME('2012-07-25');
- 'Wednesday'
 Usage :-
 Case 1 : To find DAY NAME corresponding to a particular date 
 hive SELECT DAYNAME('2012-07-25');
- 'Wednesday'
 Case 2 : To query a table to find details based on a particular day name
 Table :-
 date  |item id|store id|value|unit|price
 01/07/2012|110001|00003|0.99|1.00|0.99
 02/07/2012|110001|00008|0.99|0.00|0.00
 03/07/2012|110001|00009|0.99|0.00|0.00
 04/07/2012|110001|001112002|0.99|0.00|0.00
 05/07/2012|110001|001112003|0.99|0.00|0.00
 06/07/2012|110001|001112006|0.99|1.00|0.99
 07/07/2012|110001|001112007|0.99|0.00|0.00
 08/07/2012|110001|001112008|0.99|0.00|0.00
 09/07/2012|110001|001112009|0.99|0.00|0.00
 10/07/2012|110001|001112010|0.99|0.00|0.00
 11/07/2012|110001|001113003|0.99|0.00|0.00
 12/07/2012|110001|001113006|0.99|0.00|0.00
 13/07/2012|110001|001113008|0.99|0.00|0.00
 14/07/2012|110001|001113010|0.99|0.00|0.00
 15/07/2012|110001|001114002|0.99|0.00|0.00
 16/07/2012|110001|001114004|0.99|1.00|0.99
 17/07/2012|110001|001114005|0.99|0.00|0.00
 18/07/2012|110001|001121004|0.99|0.00|0.00
 Query : select * from sales where dayname(date)='wednesday';
 Result :-
 04/07/2012|110001|001112002|0.99|0.00|0.00
 11/07/2012|110001|001113003|0.99|0.00|0.00
 18/07/2012|110001|001121004|0.99|0.00|0.00

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Assigned] (HIVE-3299) UDF DAYNAME(date) to HIVE

2012-08-05 Thread Namitha Babychan (JIRA)

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

Namitha Babychan reassigned HIVE-3299:
--

Assignee: Carl Steinbach

 UDF  DAYNAME(date) to HIVE 
 ---

 Key: HIVE-3299
 URL: https://issues.apache.org/jira/browse/HIVE-3299
 Project: Hive
  Issue Type: New Feature
  Components: UDF
Affects Versions: 0.9.0
Reporter: Namitha Babychan
Assignee: Carl Steinbach
  Labels: patch
 Fix For: 0.10.0

 Attachments: HIVE-3299.1.patch.txt, Hive-3299_Testcase.doc, 
 hive-3299.1.patch


 Current releases of Hive lacks a function which would return the day name 
 corresponding to a date / timestamp value which might be a part of a column.  
  
 The function -DAYNAME (date) would return the day name from a date / 
 timestamp or column which would be useful while using HiveQL. This would find 
 its use  in various business sectors like retail, which would help in  
 identifying the trends and sales datails for a particular weekday for entire 
 year,month or week.
 Functionality :-
 Function Name: DAYNAME (date)

 Returns the name of the weekday for date. 
 Example: hive SELECT DAYNAME('2012-07-25');
- 'Wednesday'
 Usage :-
 Case 1 : To find DAY NAME corresponding to a particular date 
 hive SELECT DAYNAME('2012-07-25');
- 'Wednesday'
 Case 2 : To query a table to find details based on a particular day name
 Table :-
 date  |item id|store id|value|unit|price
 01/07/2012|110001|00003|0.99|1.00|0.99
 02/07/2012|110001|00008|0.99|0.00|0.00
 03/07/2012|110001|00009|0.99|0.00|0.00
 04/07/2012|110001|001112002|0.99|0.00|0.00
 05/07/2012|110001|001112003|0.99|0.00|0.00
 06/07/2012|110001|001112006|0.99|1.00|0.99
 07/07/2012|110001|001112007|0.99|0.00|0.00
 08/07/2012|110001|001112008|0.99|0.00|0.00
 09/07/2012|110001|001112009|0.99|0.00|0.00
 10/07/2012|110001|001112010|0.99|0.00|0.00
 11/07/2012|110001|001113003|0.99|0.00|0.00
 12/07/2012|110001|001113006|0.99|0.00|0.00
 13/07/2012|110001|001113008|0.99|0.00|0.00
 14/07/2012|110001|001113010|0.99|0.00|0.00
 15/07/2012|110001|001114002|0.99|0.00|0.00
 16/07/2012|110001|001114004|0.99|1.00|0.99
 17/07/2012|110001|001114005|0.99|0.00|0.00
 18/07/2012|110001|001121004|0.99|0.00|0.00
 Query : select * from sales where dayname(date)='wednesday';
 Result :-
 04/07/2012|110001|001112002|0.99|0.00|0.00
 11/07/2012|110001|001113003|0.99|0.00|0.00
 18/07/2012|110001|001121004|0.99|0.00|0.00

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




Re: Review Request: Remove the Unix specific absolute path of “Cat” utility in several .q files to make them run on Windows with CygWin in path.

2012-08-05 Thread Ashutosh Chauhan

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

Ship it!


Ship It!

- Ashutosh Chauhan


On Aug. 2, 2012, 4:51 a.m., Kanna Karanam wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/6313/
 ---
 
 (Updated Aug. 2, 2012, 4:51 a.m.)
 
 
 Review request for hive, Carl Steinbach, Edward  Capriolo, and Ashutosh 
 Chauhan.
 
 
 Description
 ---
 
 Several .q files have Unix absolute paths for Cat utility so all of them are 
 failing on Windows even with CygWin support. 
 
 
 This addresses bug HIVE-3327.
 https://issues.apache.org/jira/browse/HIVE-3327
 
 
 Diffs
 -
 
   trunk/contrib/src/test/queries/clientpositive/serde_typedbytes.q 1368192 
   trunk/contrib/src/test/queries/clientpositive/serde_typedbytes2.q 1368192 
   trunk/contrib/src/test/queries/clientpositive/serde_typedbytes3.q 1368192 
   trunk/contrib/src/test/queries/clientpositive/serde_typedbytes4.q 1368192 
   trunk/contrib/src/test/results/clientpositive/serde_typedbytes.q.out 
 1368192 
   trunk/contrib/src/test/results/clientpositive/serde_typedbytes2.q.out 
 1368192 
   trunk/contrib/src/test/results/clientpositive/serde_typedbytes3.q.out 
 1368192 
   trunk/contrib/src/test/results/clientpositive/serde_typedbytes4.q.out 
 1368192 
   trunk/ql/src/test/queries/clientnegative/clusterbydistributeby.q 1368192 
   trunk/ql/src/test/queries/clientnegative/clusterbyorderby.q 1368192 
   trunk/ql/src/test/queries/clientnegative/clusterbysortby.q 1368192 
   trunk/ql/src/test/queries/clientnegative/orderbysortby.q 1368192 
   trunk/ql/src/test/queries/clientpositive/input14.q 1368192 
   trunk/ql/src/test/queries/clientpositive/input14_limit.q 1368192 
   trunk/ql/src/test/queries/clientpositive/input17.q 1368192 
   trunk/ql/src/test/queries/clientpositive/input18.q 1368192 
   trunk/ql/src/test/queries/clientpositive/input34.q 1368192 
   trunk/ql/src/test/queries/clientpositive/input35.q 1368192 
   trunk/ql/src/test/queries/clientpositive/input36.q 1368192 
   trunk/ql/src/test/queries/clientpositive/input38.q 1368192 
   trunk/ql/src/test/queries/clientpositive/input5.q 1368192 
   trunk/ql/src/test/queries/clientpositive/mapreduce1.q 1368192 
   trunk/ql/src/test/queries/clientpositive/mapreduce2.q 1368192 
   trunk/ql/src/test/queries/clientpositive/mapreduce3.q 1368192 
   trunk/ql/src/test/queries/clientpositive/mapreduce4.q 1368192 
   trunk/ql/src/test/queries/clientpositive/mapreduce7.q 1368192 
   trunk/ql/src/test/queries/clientpositive/mapreduce8.q 1368192 
   trunk/ql/src/test/queries/clientpositive/newline.q 1368192 
   trunk/ql/src/test/queries/clientpositive/nullscript.q 1368192 
   trunk/ql/src/test/queries/clientpositive/partcols1.q 1368192 
   trunk/ql/src/test/queries/clientpositive/ppd_transform.q 1368192 
   trunk/ql/src/test/queries/clientpositive/query_with_semi.q 1368192 
   trunk/ql/src/test/queries/clientpositive/regexp_extract.q 1368192 
   trunk/ql/src/test/queries/clientpositive/select_transform_hint.q 1368192 
   trunk/ql/src/test/queries/clientpositive/transform_ppr1.q 1368192 
   trunk/ql/src/test/queries/clientpositive/transform_ppr2.q 1368192 
   trunk/ql/src/test/results/clientpositive/input14.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/input14_limit.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/input17.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/input18.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/input34.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/input35.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/input36.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/input38.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/input5.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/mapreduce1.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/mapreduce2.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/mapreduce3.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/mapreduce4.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/mapreduce7.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/mapreduce8.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/newline.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/nullscript.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/partcols1.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/ppd_transform.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/query_with_semi.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/regexp_extract.q.out 1368192 
   trunk/ql/src/test/results/clientpositive/select_transform_hint.q.out 
 1368192 
   

[jira] [Commented] (HIVE-3327) Remove the Unix specific absolute path of “Cat” utility in several .q files to make them run on Windows with CygWin in path.

2012-08-05 Thread Ashutosh Chauhan (JIRA)

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

Ashutosh Chauhan commented on HIVE-3327:


+1 Running tests.

 Remove the Unix specific absolute path of “Cat” utility in several .q files 
 to make them run on Windows with CygWin in path.
 

 Key: HIVE-3327
 URL: https://issues.apache.org/jira/browse/HIVE-3327
 Project: Hive
  Issue Type: Sub-task
  Components: Tests, Windows
Affects Versions: 0.9.0, 0.9.1
Reporter: Kanna Karanam
Assignee: Kanna Karanam
  Labels: Windows
 Fix For: 0.10.0, 0.9.1

 Attachments: HIVE-3327.1.patch.txt


 Several .q files have Unix absolute paths for Cat utility so all of them are 
 failing on Windows even with CygWin support. 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira