Thomas Tauber-Marshall has posted comments on this change. Change subject: IMPALA-2805: Order conjuncts based on selectivity and cost ......................................................................
Patch Set 16: (2 comments) http://gerrit.cloudera.org:8080/#/c/2598/16/fe/src/main/java/com/cloudera/impala/analysis/BinaryPredicate.java File fe/src/main/java/com/cloudera/impala/analysis/BinaryPredicate.java: Line 260: getAvgStringLength(getChild(1)) * BINARY_PREDICATE_COST); > you multiply costs, so this is quadratic cost? i think the lengths should b Yeah, you're right. It's linear. http://gerrit.cloudera.org:8080/#/c/2598/16/fe/src/main/java/com/cloudera/impala/analysis/LikePredicate.java File fe/src/main/java/com/cloudera/impala/analysis/LikePredicate.java: Line 147: evalCost_ = getChildCosts() + (float) (getAvgStringLength(getChild(0)) * > is like typically quadratic? It depends on the wildcards used and their position in the pattern. Do you have a recommendation here? I would guess the most common thing would be a single wildcard at either the beginning or end, which I think would be linear, so maybe that's the right thing to do for now? -- To view, visit http://gerrit.cloudera.org:8080/2598 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: I02279a26fbc6308ac5eb819d78345fc010469034 Gerrit-PatchSet: 16 Gerrit-Project: Impala Gerrit-Branch: cdh5-trunk Gerrit-Owner: Thomas Tauber-Marshall <[email protected]> Gerrit-Reviewer: Alex Behm <[email protected]> Gerrit-Reviewer: Henry Robinson <[email protected]> Gerrit-Reviewer: Marcel Kornacker <[email protected]> Gerrit-Reviewer: Matthew Jacobs <[email protected]> Gerrit-Reviewer: Mostafa Mokhtar <[email protected]> Gerrit-Reviewer: Thomas Tauber-Marshall <[email protected]> Gerrit-HasComments: Yes
