zabetak commented on code in PR #5505:
URL: https://github.com/apache/hive/pull/5505#discussion_r1924900546


##########
ql/src/test/queries/clientpositive/reducesink_dedup.q:
##########
@@ -1,3 +1,4 @@
+-- SORT_QUERY_RESULTS
 --! qt:dataset:part
 --! qt:dataset:src
 select p_name

Review Comment:
   If we add `SORT_QUERY_RESULTS` then we cannot verify the effect of `SORT BY` 
so it doesn't make much sense to have both (other than verifying that the query 
will not fail).
   
   Other than that the `SORT BY 1` semantics that you describe seem reasonable 
since they are aligned with the `GROUP BY 1` behavior. Let's add a small entry 
also in the respective 
[doc](https://github.com/apache/hive-site/blob/main/content/docs/latest/languagemanual-sortby_27362045.md)
 for this behavior.



##########
ql/src/test/queries/clientpositive/distributeby.q:
##########
@@ -0,0 +1,24 @@
+create table t1 (a string, b int);
+
+insert into t1 values ('2014-03-14 10:10:12', 10);
+
+-- distribute by
+explain cbo
+select * from t1 where a between date_add('2014-03-14', -1) and '2014-03-14' 
distribute by a;

Review Comment:
   It seems that the conversion problem is not really related to `DISTRIBUTE 
BY` but just a matter of having CBO ON/OFF so they don't fit very well in this 
file. 
   
   Regarding the correctness problem, I think it deserves a dedicated JIRA 
issue since it will still be present even after this PR gets in.
   
   For the reasons above, I think we should simplify the tests in this file to 
remove data + where clauses. If we need to add conversion/vectorization or 
other kind of tests we should do it elsewhere and probably outside this PR.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to