| Constructor and Description |
|---|
PartitionPruner() |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
hasColumnExpr(ExprNodeDesc desc)
Whether the expression contains a column node or not.
|
static boolean |
onlyContainsPartnCols(Table tab,
ExprNodeDesc expr)
Find out whether the condition only contains partitioned columns.
|
static PrunedPartitionList |
prune(TableScanOperator ts,
ParseContext parseCtx,
java.lang.String alias)
Get the partition list for the TS operator that satisfies the partition pruner
condition.
|
static boolean |
prunePartitionNames(java.util.List<java.lang.String> columnNames,
ExprNodeDesc prunerExpr,
java.lang.String defaultPartitionName,
java.util.List<java.lang.String> partNames)
Prunes partition names to see if they match the prune expression.
|
ParseContext |
transform(ParseContext pctx)
All transformation steps implement this interface.
|
public ParseContext transform(ParseContext pctx) throws SemanticException
Transformtransform in interface Transformpctx - input parse contextSemanticExceptionpublic static boolean onlyContainsPartnCols(Table tab, ExprNodeDesc expr)
tab - the table objectexpr - the pruner expression for the tablepublic static PrunedPartitionList prune(TableScanOperator ts, ParseContext parseCtx, java.lang.String alias) throws HiveException
HiveExceptionpublic static boolean prunePartitionNames(java.util.List<java.lang.String> columnNames,
ExprNodeDesc prunerExpr,
java.lang.String defaultPartitionName,
java.util.List<java.lang.String> partNames)
throws HiveException,
MetaException
columnNames - name of partition columnsprunerExpr - The expression to match.defaultPartitionName - name of default partitionpartNames - Partition names to filter. The list is modified in place.HiveExceptionMetaExceptionpublic static boolean hasColumnExpr(ExprNodeDesc desc)
Copyright © 2012 The Apache Software Foundation