Uses of Class
org.apache.calcite.rel.core.Project
-
Packages that use Project Package Description org.apache.calcite.adapter.cassandra Cassandra query provider.org.apache.calcite.adapter.druid Query provider based on a Druid database.org.apache.calcite.adapter.elasticsearch Query provider based on an Elasticsearch2 DB.org.apache.calcite.adapter.enumerable Query optimizer rules for Java calling convention.org.apache.calcite.adapter.geode.rel Query provider based on Apache Geode (Gemfire) In Memory Data Gridorg.apache.calcite.adapter.jdbc Query provider based on a JDBC data source.org.apache.calcite.adapter.mongodb Query provider based on a MongoDB database.org.apache.calcite.adapter.pig Pig query provider.org.apache.calcite.interpreter Provides an implementation of relational expressions using an interpreter.org.apache.calcite.plan Defines interfaces for constructing rule-based optimizers of relational expressions.org.apache.calcite.rel.core Defines core relational expressions.org.apache.calcite.rel.logical Defines logical relational expressions.org.apache.calcite.rel.metadata Defines metadata interfaces and utilities for relational expressions.org.apache.calcite.rel.rel2sql Translates a relational expression to SQL parse tree.org.apache.calcite.rel.rules Provides a core set of planner rules.org.apache.calcite.rex Provides a language for representing row-expressions.org.apache.calcite.sql2rel Translates a SQL parse tree to relational expression. -
-
Uses of Project in org.apache.calcite.adapter.cassandra
Subclasses of Project in org.apache.calcite.adapter.cassandra Modifier and Type Class Description class
CassandraProject
Implementation ofProject
relational expression in Cassandra.Methods in org.apache.calcite.adapter.cassandra that return Project Modifier and Type Method Description Project
CassandraProject. copy(RelTraitSet traitSet, RelNode input, java.util.List<RexNode> projects, RelDataType rowType)
-
Uses of Project in org.apache.calcite.adapter.druid
Methods in org.apache.calcite.adapter.druid with parameters of type Project Modifier and Type Method Description protected static java.util.List<DruidQuery.JsonAggregation>
DruidQuery. computeDruidJsonAgg(java.util.List<AggregateCall> aggCalls, java.util.List<java.lang.String> aggNames, Project project, DruidQuery druidQuery)
Translates aggregate calls to DruidDruidQuery.JsonAggregation
s when possible.protected static Pair<java.util.List<java.lang.String>,java.util.List<VirtualColumn>>
DruidQuery. computeProjectAsScan(Project projectRel, RelDataType inputRowType, DruidQuery druidQuery)
Translates list of projects to Druid Column names and Virtual Columns if any We can not usePair.zip(Object[], Object[])
, since size can be differentprotected static Pair<java.util.List<DimensionSpec>,java.util.List<VirtualColumn>>
DruidQuery. computeProjectGroupSet(Project projectNode, ImmutableBitSet groupSet, RelDataType inputRowType, DruidQuery druidQuery)
Computes the project group set.protected DruidQuery.QuerySpec
DruidQuery. getQuery(RelDataType rowType, Filter filter, Project project, ImmutableBitSet groupSet, java.util.List<AggregateCall> aggCalls, java.util.List<java.lang.String> aggNames, java.util.List<java.lang.Integer> collationIndexes, java.util.List<RelFieldCollation.Direction> collationDirections, ImmutableBitSet numericCollationIndexes, java.lang.Integer fetch, Project postProject, Filter havingFilter)
private DruidQuery
DruidRules.DruidAggregateProjectRule. optimizeFilteredAggregations(RelOptRuleCall call, DruidQuery query, Project project, Aggregate aggregate)
Attempts to optimize any aggregations with filters in the DruidQuery. -
Uses of Project in org.apache.calcite.adapter.elasticsearch
Subclasses of Project in org.apache.calcite.adapter.elasticsearch Modifier and Type Class Description class
ElasticsearchProject
Implementation ofProject
relational expression in Elasticsearch.Methods in org.apache.calcite.adapter.elasticsearch that return Project Modifier and Type Method Description Project
ElasticsearchProject. copy(RelTraitSet relTraitSet, RelNode input, java.util.List<RexNode> projects, RelDataType relDataType)
-
Uses of Project in org.apache.calcite.adapter.enumerable
Subclasses of Project in org.apache.calcite.adapter.enumerable Modifier and Type Class Description class
EnumerableProject
Implementation ofProject
inenumerable calling convention
. -
Uses of Project in org.apache.calcite.adapter.geode.rel
Subclasses of Project in org.apache.calcite.adapter.geode.rel Modifier and Type Class Description class
GeodeProject
Implementation ofProject
relational expression in Geode.Methods in org.apache.calcite.adapter.geode.rel that return Project Modifier and Type Method Description Project
GeodeProject. copy(RelTraitSet traitSet, RelNode input, java.util.List<RexNode> projects, RelDataType rowType)
-
Uses of Project in org.apache.calcite.adapter.jdbc
Subclasses of Project in org.apache.calcite.adapter.jdbc Modifier and Type Class Description static class
JdbcRules.JdbcProject
Implementation ofProject
injdbc calling convention
.Methods in org.apache.calcite.adapter.jdbc with parameters of type Project Modifier and Type Method Description private static boolean
JdbcRules.JdbcProjectRule. userDefinedFunctionInProject(Project project)
-
Uses of Project in org.apache.calcite.adapter.mongodb
Subclasses of Project in org.apache.calcite.adapter.mongodb Modifier and Type Class Description class
MongoProject
Implementation ofProject
relational expression in MongoDB.Methods in org.apache.calcite.adapter.mongodb that return Project Modifier and Type Method Description Project
MongoProject. copy(RelTraitSet traitSet, RelNode input, java.util.List<RexNode> projects, RelDataType rowType)
-
Uses of Project in org.apache.calcite.adapter.pig
Subclasses of Project in org.apache.calcite.adapter.pig Modifier and Type Class Description class
PigProject
Implementation ofProject
inPig calling convention
.Methods in org.apache.calcite.adapter.pig that return Project Modifier and Type Method Description Project
PigProject. copy(RelTraitSet traitSet, RelNode input, java.util.List<RexNode> projects, RelDataType rowType)
-
Uses of Project in org.apache.calcite.interpreter
Subclasses of Project in org.apache.calcite.interpreter Modifier and Type Class Description static class
Bindables.BindableProject
Implementation ofProject
in bindable calling convention.Methods in org.apache.calcite.interpreter with parameters of type Project Modifier and Type Method Description void
Nodes.CoreCompiler. visit(Project project)
Constructors in org.apache.calcite.interpreter with parameters of type Project Constructor Description ProjectNode(Compiler compiler, Project rel)
-
Uses of Project in org.apache.calcite.plan
Fields in org.apache.calcite.plan with type parameters of type Project Modifier and Type Field Description static com.google.common.base.Predicate<Project>
RelOptUtil. PROJECT_PREDICATE
Deprecated.Methods in org.apache.calcite.plan with parameters of type Project Modifier and Type Method Description static boolean
RelOptUtil. checkProjAndChildInputs(Project project, boolean checkNames)
Deprecated.static boolean
RelOptUtil. containsMultisetOrWindowedAgg(Project project)
Predicate for whether aProject
contains multisets or windowed aggregates.static RexNode
RelOptUtil. pushFilterPastProject(RexNode filter, Project projRel)
Deprecated.static java.util.List<RexNode>
RelOptUtil. pushPastProject(java.util.List<? extends RexNode> nodes, Project project)
Converts a list of expressions that are based on the output fields of aProject
to equivalent expressions on the Project's input fields.static RexNode
RelOptUtil. pushPastProject(RexNode node, Project project)
Converts an expression that is based on the output fields of aProject
to an equivalent expression on the Project's input fields.private static RexShuttle
RelOptUtil. pushShuttle(Project project)
-
Uses of Project in org.apache.calcite.rel.core
Methods in org.apache.calcite.rel.core that return Project Modifier and Type Method Description abstract Project
Project. copy(RelTraitSet traitSet, RelNode input, java.util.List<RexNode> projects, RelDataType rowType)
Copies a project.Project
Project. copy(RelTraitSet traitSet, RelNode input, java.util.List<RexNode> projects, RelDataType rowType, int flags)
Deprecated. -
Uses of Project in org.apache.calcite.rel.logical
Subclasses of Project in org.apache.calcite.rel.logical Modifier and Type Class Description class
LogicalProject
Sub-class ofProject
not targeted at any particular engine or calling convention. -
Uses of Project in org.apache.calcite.rel.metadata
Fields in org.apache.calcite.rel.metadata declared as Project Modifier and Type Field Description private Project
RelMdUtil.CardOfProjExpr. rel
Methods in org.apache.calcite.rel.metadata with parameters of type Project Modifier and Type Method Description java.lang.Boolean
RelMdColumnUniqueness. areColumnsUnique(Project rel, RelMetadataQuery mq, ImmutableBitSet columns, boolean ignoreNulls)
java.util.List<java.lang.Double>
RelMdSize. averageColumnSizes(Project rel, RelMetadataQuery mq)
static java.lang.Double
RelMdUtil. cardOfProjExpr(RelMetadataQuery mq, Project rel, RexNode expr)
Computes the cardinality of a particular expression from the projection list.com.google.common.collect.ImmutableList<RelCollation>
RelMdCollation. collations(Project project, RelMetadataQuery mq)
RelDistribution
RelMdDistribution. distribution(Project project, RelMetadataQuery mq)
RelOptPredicateList
RelMdAllPredicates. getAllPredicates(Project project, RelMetadataQuery mq)
Extract predicates for a project.java.util.Set<RelColumnOrigin>
RelMdColumnOrigins. getColumnOrigins(Project rel, RelMetadataQuery mq, int iOutputColumn)
java.lang.Double
RelMdDistinctRowCount. getDistinctRowCount(Project rel, RelMetadataQuery mq, ImmutableBitSet groupKey, RexNode predicate)
java.util.Set<RexNode>
RelMdExpressionLineage. getExpressionLineage(Project rel, RelMetadataQuery mq, RexNode outputExpression)
Expression lineage from Project.java.lang.Double
RelMdMaxRowCount. getMaxRowCount(Project rel, RelMetadataQuery mq)
java.lang.Double
RelMdMinRowCount. getMinRowCount(Project rel, RelMetadataQuery mq)
com.google.common.collect.Multimap<java.lang.Class<? extends RelNode>,RelNode>
RelMdNodeTypes. getNodeTypes(Project rel, RelMetadataQuery mq)
java.lang.Double
RelMdPopulationSize. getPopulationSize(Project rel, RelMetadataQuery mq, ImmutableBitSet groupKey)
RelOptPredicateList
RelMdPredicates. getPredicates(Project project, RelMetadataQuery mq)
Infers predicates for a project.java.lang.Double
RelMdRowCount. getRowCount(Project rel, RelMetadataQuery mq)
java.lang.Double
RelMdSelectivity. getSelectivity(Project rel, RelMetadataQuery mq, RexNode predicate)
java.util.Set<RexTableInputRef.RelTableRef>
RelMdTableReferences. getTableReferences(Project rel, RelMetadataQuery mq)
Table references from Project.java.util.Set<ImmutableBitSet>
RelMdUniqueKeys. getUniqueKeys(Project rel, RelMetadataQuery mq, boolean ignoreNulls)
Constructors in org.apache.calcite.rel.metadata with parameters of type Project Constructor Description CardOfProjExpr(RelMetadataQuery mq, Project rel)
-
Uses of Project in org.apache.calcite.rel.rel2sql
Methods in org.apache.calcite.rel.rel2sql with parameters of type Project Modifier and Type Method Description SqlImplementor.Result
RelToSqlConverter. visit(Project e)
-
Uses of Project in org.apache.calcite.rel.rules
Fields in org.apache.calcite.rel.rules declared as Project Modifier and Type Field Description private Project
AbstractMaterializedViewRule.ViewPartialRewriting. newTopViewProject
private Project
PushProjector. origProj
Methods in org.apache.calcite.rel.rules that return Project Modifier and Type Method Description Project
PushProjector. createProjectRefsAndExprs(RelNode projChild, boolean adjust, boolean rightSide)
Creates a projection based on the inputs specified in a bitmap and the expressions that need to be preserved.protected Project
JoinProjectTransposeRule. getRightChild(RelOptRuleCall call)
Methods in org.apache.calcite.rel.rules with parameters of type Project Modifier and Type Method Description static RelNode
AggregateProjectMergeRule. apply(RelOptRuleCall call, Aggregate aggregate, Project project)
protected void
AggregateStarTableRule. apply(RelOptRuleCall call, Project postProject, Aggregate aggregate, StarTable.StarTableScan scan)
protected void
ProjectTableScanRule. apply(RelOptRuleCall call, Project project, TableScan scan)
protected abstract AbstractMaterializedViewRule.ViewPartialRewriting
AbstractMaterializedViewRule. compensateViewPartial(RelBuilder relBuilder, RexBuilder rexBuilder, RelMetadataQuery mq, RelNode input, Project topProject, RelNode node, java.util.Set<RexTableInputRef.RelTableRef> queryTableRefs, AbstractMaterializedViewRule.EquivalenceClasses queryEC, Project topViewProject, RelNode viewNode, java.util.Set<RexTableInputRef.RelTableRef> viewTableRefs)
It checks whether the query can be rewritten using the view even though the query uses additional tables.protected AbstractMaterializedViewRule.ViewPartialRewriting
AbstractMaterializedViewRule.MaterializedViewAggregateRule. compensateViewPartial(RelBuilder relBuilder, RexBuilder rexBuilder, RelMetadataQuery mq, RelNode input, Project topProject, RelNode node, java.util.Set<RexTableInputRef.RelTableRef> queryTableRefs, AbstractMaterializedViewRule.EquivalenceClasses queryEC, Project topViewProject, RelNode viewNode, java.util.Set<RexTableInputRef.RelTableRef> viewTableRefs)
protected AbstractMaterializedViewRule.ViewPartialRewriting
AbstractMaterializedViewRule.MaterializedViewJoinRule. compensateViewPartial(RelBuilder relBuilder, RexBuilder rexBuilder, RelMetadataQuery mq, RelNode input, Project topProject, RelNode node, java.util.Set<RexTableInputRef.RelTableRef> queryTableRefs, AbstractMaterializedViewRule.EquivalenceClasses queryEC, Project topViewProject, RelNode viewNode, java.util.Set<RexTableInputRef.RelTableRef> viewTableRefs)
protected void
JoinProjectTransposeRule. createProjectExprs(Project projRel, RelNode joinChild, int adjustmentAmount, RexBuilder rexBuilder, java.util.List<RelDataTypeField> joinChildrenFields, java.util.List<Pair<RexNode,java.lang.String>> projects)
Creates projection expressions corresponding to one of the inputs into the joinprotected RelNode
JoinProjectTransposeRule. getProjectChild(RelOptRuleCall call, Project project, boolean leftChild)
Returns the child of the project that will be used as input into the new LogicalJoin once the projects are pulled above the LogicalJoin.static boolean
ProjectRemoveRule. isTrivial(Project project)
protected abstract boolean
AbstractMaterializedViewRule. isValidPlan(Project topProject, RelNode node, RelMetadataQuery mq)
protected boolean
AbstractMaterializedViewRule.MaterializedViewAggregateRule. isValidPlan(Project topProject, RelNode node, RelMetadataQuery mq)
protected boolean
AbstractMaterializedViewRule.MaterializedViewJoinRule. isValidPlan(Project topProject, RelNode node, RelMetadataQuery mq)
protected static AbstractMaterializedViewRule.ViewPartialRewriting
AbstractMaterializedViewRule.ViewPartialRewriting. of(RelNode newView, Project newTopViewProject, RelNode newViewNode)
protected void
AbstractMaterializedViewRule. perform(RelOptRuleCall call, Project topProject, RelNode node)
Rewriting logic is based on "Optimizing Queries Using Materialized Views: A Practical, Scalable Solution" by Goldstein and Larson.protected void
SemiJoinRule. perform(RelOptRuleCall call, Project project, Join join, RelNode left, Aggregate aggregate)
protected RelNode
AbstractMaterializedViewRule.MaterializedViewAggregateRule. rewriteQuery(RelBuilder relBuilder, RexBuilder rexBuilder, RexSimplify simplify, RelMetadataQuery mq, RexNode compensationColumnsEquiPred, RexNode otherCompensationPred, Project topProject, RelNode node, com.google.common.collect.BiMap<RexTableInputRef.RelTableRef,RexTableInputRef.RelTableRef> queryToViewTableMapping, AbstractMaterializedViewRule.EquivalenceClasses viewEC, AbstractMaterializedViewRule.EquivalenceClasses queryEC)
protected RelNode
AbstractMaterializedViewRule.MaterializedViewJoinRule. rewriteQuery(RelBuilder relBuilder, RexBuilder rexBuilder, RexSimplify simplify, RelMetadataQuery mq, RexNode compensationColumnsEquiPred, RexNode otherCompensationPred, Project topProject, RelNode node, com.google.common.collect.BiMap<RexTableInputRef.RelTableRef,RexTableInputRef.RelTableRef> viewToQueryTableMapping, AbstractMaterializedViewRule.EquivalenceClasses viewEC, AbstractMaterializedViewRule.EquivalenceClasses queryEC)
protected abstract RelNode
AbstractMaterializedViewRule. rewriteQuery(RelBuilder relBuilder, RexBuilder rexBuilder, RexSimplify simplify, RelMetadataQuery mq, RexNode compensationColumnsEquiPred, RexNode otherCompensationPred, Project topProject, RelNode node, com.google.common.collect.BiMap<RexTableInputRef.RelTableRef,RexTableInputRef.RelTableRef> viewToQueryTableMapping, AbstractMaterializedViewRule.EquivalenceClasses viewEC, AbstractMaterializedViewRule.EquivalenceClasses queryEC)
If the view will be used in a union rewriting, this method is responsible for rewriting the query branch of the union using the given compensation predicate.protected RelNode
AbstractMaterializedViewRule.MaterializedViewAggregateRule. rewriteView(RelBuilder relBuilder, RexBuilder rexBuilder, RexSimplify simplify, RelMetadataQuery mq, AbstractMaterializedViewRule.MatchModality matchModality, boolean unionRewriting, RelNode input, Project topProject, RelNode node, Project topViewProject, RelNode viewNode, com.google.common.collect.BiMap<RexTableInputRef.RelTableRef,RexTableInputRef.RelTableRef> queryToViewTableMapping, AbstractMaterializedViewRule.EquivalenceClasses queryEC)
protected RelNode
AbstractMaterializedViewRule.MaterializedViewJoinRule. rewriteView(RelBuilder relBuilder, RexBuilder rexBuilder, RexSimplify simplify, RelMetadataQuery mq, AbstractMaterializedViewRule.MatchModality matchModality, boolean unionRewriting, RelNode input, Project topProject, RelNode node, Project topViewProject, RelNode viewNode, com.google.common.collect.BiMap<RexTableInputRef.RelTableRef,RexTableInputRef.RelTableRef> queryToViewTableMapping, AbstractMaterializedViewRule.EquivalenceClasses queryEC)
protected abstract RelNode
AbstractMaterializedViewRule. rewriteView(RelBuilder relBuilder, RexBuilder rexBuilder, RexSimplify simplify, RelMetadataQuery mq, AbstractMaterializedViewRule.MatchModality matchModality, boolean unionRewriting, RelNode input, Project topProject, RelNode node, Project topViewProject, RelNode viewNode, com.google.common.collect.BiMap<RexTableInputRef.RelTableRef,RexTableInputRef.RelTableRef> queryToViewTableMapping, AbstractMaterializedViewRule.EquivalenceClasses queryEC)
Rewrites the query using the given view query.static RelNode
ProjectRemoveRule. strip(Project project)
Returns the child of a project if the project is trivial, otherwise the project itself.Constructors in org.apache.calcite.rel.rules with parameters of type Project Constructor Description PushProjector(Project origProj, RexNode origFilter, RelNode childRel, PushProjector.ExprCondition preserveExprCondition, RelBuilder relBuilder)
Creates a PushProjector object for pushing projects past a RelNode.ViewPartialRewriting(RelNode newView, Project newTopViewProject, RelNode newViewNode)
Constructor parameters in org.apache.calcite.rel.rules with type arguments of type Project Constructor Description ProjectFilterTransposeRule(java.lang.Class<? extends Project> projectClass, java.lang.Class<? extends Filter> filterClass, RelBuilderFactory relBuilderFactory, PushProjector.ExprCondition preserveExprCondition)
Creates a ProjectFilterTransposeRule.ProjectReduceExpressionsRule(java.lang.Class<? extends Project> projectClass, boolean matchNullability, RelBuilderFactory relBuilderFactory)
ProjectReduceExpressionsRule(java.lang.Class<? extends Project> projectClass, RelBuilderFactory relBuilderFactory)
Deprecated.ProjectSortTransposeRule(java.lang.Class<Project> projectClass, java.lang.Class<Sort> sortClass, RelBuilderFactory relBuilderFactory)
Creates a ProjectSortTransposeRule.ProjectToSemiJoinRule(java.lang.Class<Project> projectClass, java.lang.Class<Join> joinClass, java.lang.Class<Aggregate> aggregateClass, RelBuilderFactory relBuilderFactory, java.lang.String description)
Creates a ProjectToSemiJoinRule.SemiJoinRule(java.lang.Class<Project> projectClass, java.lang.Class<Join> joinClass, java.lang.Class<Aggregate> aggregateClass, RelBuilderFactory relBuilderFactory, java.lang.String description)
-
Uses of Project in org.apache.calcite.rex
Fields in org.apache.calcite.rex with type parameters of type Project Modifier and Type Field Description static com.google.common.base.Predicate<Project>
RexUtil.SubQueryFinder. PROJECT_PREDICATE
Deprecated.Methods in org.apache.calcite.rex with parameters of type Project Modifier and Type Method Description static boolean
RexUtil.SubQueryFinder. containsSubQuery(Project project)
Returns whether aProject
contains a sub-query. -
Uses of Project in org.apache.calcite.sql2rel
Methods in org.apache.calcite.sql2rel with parameters of type Project Modifier and Type Method Description RelFieldTrimmer.TrimResult
RelFieldTrimmer. trimFields(Project project, ImmutableBitSet fieldsUsed, java.util.Set<RelDataTypeField> extraFields)
-