diff options
author | Arina Ielchiieva <arina.yelchiyeva@gmail.com> | 2017-12-21 19:31:00 +0200 |
---|---|---|
committer | Aman Sinha <asinha@maprtech.com> | 2018-02-24 19:56:35 -0800 |
commit | 9073aed67d89e8b2188870d6c812706085c9c41b (patch) | |
tree | 029107ed8529fa587ef30ce544e4dd300d72cd9f /logical | |
parent | 50efb806bb03494e1da4d6b48f90fbf58d699c18 (diff) |
DRILL-6118: Handle item star columns during project / filter push down and directory pruning
1. Added DrillFilterItemStarReWriterRule to re-write item star fields to regular field references.
2. Refactored DrillPushProjectIntoScanRule to handle item star fields, factored out helper classes and methods from PreUitl.class.
3. Fixed issue with dynamic star usage (after Calcite upgrade old usage of star was still present, replaced WILDCARD -> DYNAMIC_STAR for clarity).
4. Added unit tests to check project / filter push down and directory pruning with item star.
Diffstat (limited to 'logical')
-rw-r--r-- | logical/src/main/java/org/apache/drill/common/expression/SchemaPath.java | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/logical/src/main/java/org/apache/drill/common/expression/SchemaPath.java b/logical/src/main/java/org/apache/drill/common/expression/SchemaPath.java index 95f3dbb7c..583046a76 100644 --- a/logical/src/main/java/org/apache/drill/common/expression/SchemaPath.java +++ b/logical/src/main/java/org/apache/drill/common/expression/SchemaPath.java @@ -42,8 +42,8 @@ import com.google.common.base.Preconditions; public class SchemaPath extends LogicalExpressionBase { - public static final String WILDCARD = "*"; - public static final SchemaPath STAR_COLUMN = getSimplePath(WILDCARD); + public static final String DYNAMIC_STAR = "**"; + public static final SchemaPath STAR_COLUMN = getSimplePath(DYNAMIC_STAR); private final NameSegment rootSegment; @@ -205,14 +205,14 @@ public class SchemaPath extends LogicalExpressionBase { } /** - * Return if this column is the special wildcard ("*") column which means to + * Return if this column is the special wildcard ("**") column which means to * project all table columns. * - * @return true if the column is "*" + * @return true if the column is "**" */ - public boolean isWildcard() { - return isLeaf() && nameEquals(WILDCARD); + public boolean isDynamicStar() { + return isLeaf() && nameEquals(DYNAMIC_STAR); } /** |