public class ASTConverter extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
NON_FK_FILTERED |
static String |
NON_FK_NOT_FILTERED |
| Modifier and Type | Method and Description |
|---|---|
static ASTNode |
convert(org.apache.calcite.rel.RelNode relNode,
List<org.apache.hadoop.hive.metastore.api.FieldSchema> resultSchema,
boolean alignColumns,
PlanMapper planMapper) |
static ASTNode |
emptyPlan(org.apache.calcite.rel.type.RelDataType dataType)
This method generates the abstract syntax tree of a query does not return any rows.
|
ASTNode |
getUnionAllAST(ASTNode leftAST,
ASTNode rightAST) |
static boolean |
isFlat(org.apache.calcite.rex.RexCall call) |
public static final String NON_FK_FILTERED
public static final String NON_FK_NOT_FILTERED
public static ASTNode convert(org.apache.calcite.rel.RelNode relNode, List<org.apache.hadoop.hive.metastore.api.FieldSchema> resultSchema, boolean alignColumns, PlanMapper planMapper) throws CalciteSemanticException
CalciteSemanticExceptionpublic static ASTNode emptyPlan(org.apache.calcite.rel.type.RelDataType dataType)
RelDataType.
SELECT NULL alias0 ... NULL aliasn LIMIT 0;Due to a subsequent optimization when converting the plan to TEZ tasks adding a limit 0 enables Hive not submitting the query to TEZ application manager but returns empty result set immediately.
TOK_QUERY
TOK_INSERT
TOK_DESTINATION
TOK_DIR
TOK_TMP_FILE
TOK_SELECT
TOK_SELEXPR
TOK_FUNCTION
TOK_<type>
TOK_NULL
alias0
...
TOK_SELEXPR
TOK_FUNCTION
TOK_<type>
TOK_NULL
aliasn
TOK_LIMIT
0
0
dataType - - SchemaASTNode of the result plan.QueryProperties.getOuterQueryLimit(),
TaskCompiler.compile(ParseContext, List, Set, Set)public static boolean isFlat(org.apache.calcite.rex.RexCall call)
Copyright © 2024 The Apache Software Foundation. All rights reserved.