kasakrisz opened a new pull request, #5623: URL: https://github.com/apache/hive/pull/5623
### What changes were proposed in this pull request? * Do not create a `HiveSortLimit` operator when `hive.orderby.position.alias` is disabled and the `Order by` clause of the query has integer constants as keys. Also ignore the constants as keys when there are both column references and constant keys. * Do not create `HiveSortExchange` operator when both field collaction and distribution keys are all constants and `hive.orderby.position.alias` is disabled. Also ignore the constants as keys when there are both column references and constant keys. ### Why are the changes needed? To synchronize the Order/Sort/Distribute/Cluster by behaviors when `hive.orderby.position.alias` is disabled and CBO is enabled/disabled . ### Does this PR introduce _any_ user-facing change? Yes, the results of queries with Order/Sort/Cluster by clauses may have different order. ### Is the change a dependency upgrade? No. ### How was this patch tested? ``` mvn test -Dtest.output.overwrite -DskipSparkTests -Dtest=TestMiniLlapLocalCliDriver -Dqfile=cbo_distribute_sort_cluster_by_pos.q,cbo_rp_order_distribute_sort_cluster_by_cnst.q -pl itests/qtest -Pitests ``` -- 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]
