Class OracleIndexColumnMetaData
java.lang.Object
org.tentackle.sql.metadata.IndexColumnMetaData
org.tentackle.sql.metadata.OracleIndexColumnMetaData
- All Implemented Interfaces:
Comparable<IndexColumnMetaData>
Index column metadata for oracle.
Resolves the system-generated virtual columns oracle creates for filtered, function-based and descending indexes back to the model's view of the index, i.e. a column name, an optional function name and — for filtered indexes — the filter condition hidden in a
Resolves the system-generated virtual columns oracle creates for filtered, function-based and descending indexes back to the model's view of the index, i.e. a column name, an optional function name and — for filtered indexes — the filter condition hidden in a
CASE WHEN ... THEN ... END expression.- Author:
- harald
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordA parsed index column expression. -
Constructor Summary
ConstructorsConstructorDescriptionOracleIndexColumnMetaData(IndexMetaData indexMetaData) Creates an index column. -
Method Summary
Modifier and TypeMethodDescriptionGets the column columnName.Gets the optional function name.parseColumnExpression(String expression) Parses an index column expression as stored inALL_IND_EXPRESSIONS.
Understands theCASE WHEN <condition> THEN <expression> ENDform created for filtered indexes, theFUNC(<column>)form of function-based indexes and the plain"COLUMN"form of descending indexes.voidvalidate()Validates and post-processes the index column data.Methods inherited from class IndexColumnMetaData
compareTo, getIndexMetaData, getPosition, isDescending, setupIndexColumnFromMetaData, toString
-
Constructor Details
-
OracleIndexColumnMetaData
Creates an index column.- Parameters:
indexMetaData- the index column belongs to
-
-
Method Details
-
parseColumnExpression
Parses an index column expression as stored inALL_IND_EXPRESSIONS.
Understands theCASE WHEN <condition> THEN <expression> ENDform created for filtered indexes, theFUNC(<column>)form of function-based indexes and the plain"COLUMN"form of descending indexes. Oracle's double quotes are removed from all identifiers.- Parameters:
expression- the expression- Returns:
- the parsed expression
-
validate
public void validate()Description copied from class:IndexColumnMetaDataValidates and post-processes the index column data.- Overrides:
validatein classIndexColumnMetaData
-
getColumnName
Description copied from class:IndexColumnMetaDataGets the column columnName.- Overrides:
getColumnNamein classIndexColumnMetaData- Returns:
- the index column's columnName in lowercase
-
getFunctionName
Description copied from class:IndexColumnMetaDataGets the optional function name.- Overrides:
getFunctionNamein classIndexColumnMetaData- Returns:
- the function in uppercase, null if none
-