zabetak commented on code in PR #5505:
URL: https://github.com/apache/hive/pull/5505#discussion_r1925198901
##########
ql/src/java/org/apache/hadoop/hive/ql/parse/CalcitePlanner.java:
##########
@@ -995,12 +995,6 @@ private static String canHandleQbForCbo(QueryProperties
queryProperties,
HiveConf conf, boolean topLevelQB) {
List<String> reasons = new ArrayList<>();
// Not ok to run CBO, build error message.
- if (queryProperties.hasClusterBy()) {
- reasons.add("has cluster by");
- }
- if (queryProperties.hasDistributeBy()) {
- reasons.add("has distribute by");
- }
if (queryProperties.hasSortBy() && queryProperties.hasLimit()) {
reasons.add("has sort by with limit");
}
Review Comment:
It is a bit strange that we can handle `SORT BY` but not `SORT BY ... LIMIT`
but I guess is outside the scope of 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]