public class OverScope extends ListScope
This object is both a SqlValidatorScope
only. In the query
SELECT name FROM ( SELECT * FROM emp OVER ( ORDER BY empno RANGE BETWEEN 2 PRECEDING AND 2 FOLLOWING))
We need to use the OverScope
as a SqlValidatorNamespace
when resolving names used in the window specification.
SqlValidatorScope.EmptyPath, SqlValidatorScope.Path, SqlValidatorScope.Resolve, SqlValidatorScope.Resolved, SqlValidatorScope.ResolvedImpl, SqlValidatorScope.Step
Modifier and Type | Field and Description |
---|---|
private SqlCall |
overCall |
parent, validator
Constructor and Description |
---|
OverScope(SqlValidatorScope parent,
SqlCall overCall)
Creates a scope corresponding to a SELECT clause.
|
Modifier and Type | Method and Description |
---|---|
SqlMonotonicity |
getMonotonicity(SqlNode expr)
Returns whether an expression is monotonic in this scope.
|
SqlNode |
getNode()
Returns the root node of this scope.
|
addChild, findAliases, findAllColumnNames, findQualifyingTableName, findQualifyingTableNames, getChildNames, getChildren, resolve, resolveColumn
addColumnNames, fullyQualify, getOperandScope, getOrderList, getParent, getTableNamespace, getValidator, lookupWindow, nullifyType, resolveInNamespace, resolveTable, validateExpr
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
isWithin
private final SqlCall overCall
OverScope(SqlValidatorScope parent, SqlCall overCall)
parent
- Parent scope, or nulloverCall
- Call to OVER operatorpublic SqlNode getNode()
SqlValidatorScope
public SqlMonotonicity getMonotonicity(SqlNode expr)
SqlValidatorScope
getMonotonicity
in interface SqlValidatorScope
getMonotonicity
in class DelegatingScope
Copyright © 2012–2019 The Apache Software Foundation. All rights reserved.