public interface ModifiableView extends Table
ModifiableTable
.
It describes how its columns map onto the underlying table's columns, and any constraints that incoming rows must satisfy.
For example, given
CREATE TABLE emps (empno INTEGER, gender VARCHAR(1), deptno INTEGER); CREATE VIEW female_emps AS SELECT empno, deptno FROM emps WHERE gender = 'F';
constraint is $1 = 'F'
and column mapping is [0, 2]
.
NOTE: The current API is inefficient and experimental. It will change without notice.
Modifier and Type | Method and Description |
---|---|
ImmutableIntList |
getColumnMapping()
Returns the column mapping onto another table.
|
RexNode |
getConstraint(RexBuilder rexBuilder,
RelDataType tableRowType)
Returns a constraint that each candidate row must satisfy.
|
Table |
getTable()
Returns the underlying table.
|
Path |
getTablePath()
Returns the full path of the underlying table.
|
getJdbcTableType, getRowType, getStatistic, isRolledUp, rolledUpColumnValidInsideAgg
RexNode getConstraint(RexBuilder rexBuilder, RelDataType tableRowType)
Never null; if there is no constraint, returns "true".
rexBuilder
- Rex buildertableRowType
- Row type of the table that this view maps ontoImmutableIntList getColumnMapping()
mapping[i]
contains the column of the underlying table that the
i
th column of the view comes from, or -1 if it is based on an
expression.
Table getTable()
Path getTablePath()
Copyright © 2012–2019 The Apache Software Foundation. All rights reserved.