| java.lang.Object org.apache.derby.impl.sql.compile.VerifyAggregateExpressionsVisitor
VerifyAggregateExpressionsVisitor | public class VerifyAggregateExpressionsVisitor implements Visitor(Code) | | If a RCL (SELECT list) contains an aggregate, then we must verify
that the RCL (SELECT list) is valid.
For ungrouped queries,
the RCL must be composed entirely of valid aggregate expressions -
in this case, no column references outside of an aggregate.
For grouped aggregates,
the RCL must be composed of grouping columns or valid aggregate
expressions - in this case, the only column references allowed outside of
an aggregate are grouping columns.
author: jamie, from code written by jerry |
Method Summary | |
public boolean | skipChildren(Visitable node) Don't visit children under an aggregate, subquery or any node which
is equivalent to any of the group by expressions. | public boolean | stopTraversal() | public Visitable | visit(Visitable node) Verify that this expression is ok
for an aggregate query. |
VerifyAggregateExpressionsVisitor | public VerifyAggregateExpressionsVisitor(GroupByList groupByList)(Code) | | |
skipChildren | public boolean skipChildren(Visitable node) throws StandardException(Code) | | Don't visit children under an aggregate, subquery or any node which
is equivalent to any of the group by expressions.
Parameters: node - the node to process true/false throws: StandardException - |
stopTraversal | public boolean stopTraversal()(Code) | | |
visit | public Visitable visit(Visitable node) throws StandardException(Code) | | Verify that this expression is ok
for an aggregate query.
Parameters: node - the node to process me exception: StandardException - on ColumnReference notin group by list, ValueNode or JavaValueNode that isn't under anaggregate |
|
|