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

Hive QA commented on HIVE-21802:
--------------------------------



Here are the results of testing the latest attachment:
https://issues.apache.org/jira/secure/attachment/12970175/HIVE-21802.2.patch

{color:green}SUCCESS:{color} +1 due to 1 test(s) being added or modified.

{color:red}ERROR:{color} -1 due to 12 failed/errored test(s), 16064 tests 
executed
*Failed tests:*
{noformat}
org.apache.hadoop.hive.cli.TestCliDriver.testCliDriver[ba_table_union] 
(batchId=24)
org.apache.hadoop.hive.cli.TestCliDriver.testCliDriver[cbo_SortUnionTransposeRule]
 (batchId=17)
org.apache.hadoop.hive.cli.TestCliDriver.testCliDriver[order_by_pos] 
(batchId=65)
org.apache.hadoop.hive.cli.TestCliDriver.testCliDriver[union_pos_alias] 
(batchId=57)
org.apache.hadoop.hive.cli.TestMiniLlapLocalCliDriver.testCliDriver[lineage2] 
(batchId=176)
org.apache.hadoop.hive.cli.TestNegativeCliDriver.testCliDriver[unionOrderBy] 
(batchId=100)
org.apache.hadoop.hive.cli.TestNegativeCliDriver.testCliDriver[windowing_after_orderby]
 (batchId=100)
org.apache.hadoop.hive.cli.TestSparkPerfCliDriver.testCliDriver[query49] 
(batchId=288)
org.apache.hadoop.hive.cli.TestTezPerfCliDriver.testCliDriver[cbo_query49] 
(batchId=286)
org.apache.hadoop.hive.cli.TestTezPerfCliDriver.testCliDriver[query49] 
(batchId=286)
org.apache.hadoop.hive.cli.TestTezPerfConstraintsCliDriver.testCliDriver[cbo_query49]
 (batchId=286)
org.apache.hadoop.hive.cli.TestTezPerfConstraintsCliDriver.testCliDriver[query49]
 (batchId=286)
{noformat}

Test results: 
https://builds.apache.org/job/PreCommit-HIVE-Build/17345/testReport
Console output: https://builds.apache.org/job/PreCommit-HIVE-Build/17345/console
Test logs: http://104.198.109.242/logs/PreCommit-HIVE-Build-17345/

Messages:
{noformat}
Executing org.apache.hive.ptest.execution.TestCheckPhase
Executing org.apache.hive.ptest.execution.PrepPhase
Executing org.apache.hive.ptest.execution.YetusPhase
Executing org.apache.hive.ptest.execution.ExecutionPhase
Executing org.apache.hive.ptest.execution.ReportingPhase
Tests exited with: TestsFailedException: 12 tests failed
{noformat}

This message is automatically generated.

ATTACHMENT ID: 12970175 - PreCommit-HIVE-Build

> Add support of multilpe ORDER BY clause position
> ------------------------------------------------
>
>                 Key: HIVE-21802
>                 URL: https://issues.apache.org/jira/browse/HIVE-21802
>             Project: Hive
>          Issue Type: Bug
>          Components: Parser, Query Processor
>            Reporter: Oleksiy Sayankin
>            Assignee: Oleksiy Sayankin
>            Priority: Critical
>         Attachments: HIVE-21802.1.patch, HIVE-21802.2.patch
>
>
> *STEPS TO REPRODUCE:*
> 1. Create a table:
> {code:java}
> CREATE TABLE i (id INT, a1 INT, b1 BOOLEAN);
> {code}
> 2. Run the query which was working in Hive-1.2: ({{ORDER}} clause _before_ 
> {{WINDOW}})
> {code:java}
> SELECT id
> FROM ( 
>     SELECT 
>         id, 
>         a1,  
>         ROW_NUMBER() OVER w1 AS rn, 
>         b1 
>     FROM i a
>     ORDER BY id, b1, a1 DESC
>     WINDOW w1 as (PARTITION BY id, b1 ORDER BY a1 DESC)
> ) tmp WHERE rn=1 DISTRIBUTE BY id;
> {code}
> *ACTUAL RESULT:*
> The query fails with an exception you can find above.
> The query from Step 2 which works for Hive-2.3 is ( ({{ORDER}} clause _after_ 
> {{WINDOW}})):
> {code:java}
> SELECT id
> FROM ( 
>     SELECT 
>         id, 
>         a1,  
>         ROW_NUMBER() OVER w1 AS rn, 
>         b1 
>     FROM i a
>     WINDOW w1 as (PARTITION BY id, b1 ORDER BY a1 DESC)
>     ORDER BY id, b1, a1 DESC
> ) tmp WHERE rn=1 DISTRIBUTE BY id;
> {code}
>  Hive-2.3 also fails to parse subquery ( ({{ORDER}} clause _before_ 
> {{WINDOW}})):
> {code:java}
>     SELECT 
>         id, 
>         a1,  
>         ROW_NUMBER() OVER w1 AS rn, 
>         b1 
>     FROM i a
>     ORDER BY id, b1, a1 DESC
>     WINDOW w1 as (PARTITION BY id, b1 ORDER BY a1 DESC)
> {code}
> Customer is facing issue regularly this is occurring after upgrade . the 
> workaround given by us need lot of code changes which will get them back to 
> squire one they need to follow process and will cost them a lot. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to