Package org.apache.calcite.sql.type
package org.apache.calcite.sql.type
SQL type system.

ClassDescriptionAbstract base class for SQL implementations of
RelDataType
.Parameter typechecking strategy where types must be Array and Array element type.Parameter type checking strategy, where the operand size is 3, and the first type is array, the second type is integer, and the third type is the component type of the first array ( strictly matched without leastRestrictive conversion).SQL array type.AssignableOperandTypeChecker implementsSqlOperandTypeChecker
by verifying that the type of each argument is assignable to a predefined set of parameter types (under the SQL definition of "assignable").BasicSqlType represents a standard atomic SQL type (excluding interval types).Type checking strategy which verifies that types have the required attributes to be used as arguments to comparison operators.This class allows multiple existingSqlOperandTypeChecker
rules to be combined into one rule.How operands are composed.Allows multipleSqlSingleOperandTypeChecker
rules to be combined into one rule.Returns the rowtype of a cursor of the operand at a particular 0based ordinal position.Parameter typechecking strategy for Explicit Type.ExplicitOperandTypeInferences implementsSqlOperandTypeInference
by explicitly supplying a type for each parameter.ASqlReturnTypeInference
which always returns the same SQL type.Holds constants associated with SQL types introduced after the earliest version of Java supported by Farrago (this currently means anything introduced in JDK 1.6 or later).Operand typechecking strategy which checks operands for inclusion in type families.Function type.An operand type checker that supports implicit type cast, seeTypeCoercion.builtinFunctionCoercion(SqlCallBinding, List, List)
for details.Strategies for inferring operand types.Parameter typechecking strategy whether the operand must be an interval.IntervalSqlType represents a standard SQL datetime interval type.JavaToSqlTypeConversionRules defines mappings from common Java types to corresponding SQL types.Parameter typechecking strategy type must be a literal (whether null is allowed is determined by the constructor).SQL map type.Returns the first type that matches a set of givenSqlTypeName
s.Measure SQL type.Parameter typechecking strategy where types must be ([nullable] Multiset, [nullable] Multiset), and the two types must have the same element type.MultisetSqlType represents a standard SQL2003 multiset type.This class provides nonnullable accessors for common getters.Parameter typechecking strategy where all operand types must not be NULL.ObjectSqlType represents an SQL structured userdefined type.Strategies for handling operands.Operand typechecking strategy userdefined functions (including userdefined aggregate functions, table functions, and table macros).Strategies to check for allowed operand types of an operator call.Strategies for checking operand types.Returns the type of the operand at a particular 0based ordinal position.A collection of returntype inference strategies.Parameter typechecking strategy where the type of operand I must be comparable with the type of operand I1, for all legal values of I.Parameter typechecking strategy where all operand types except last one must be the same.Parameter typechecking strategy for a set operator (UNION, INTERSECT, EXCEPT).Helpers forSqlOperandCountRange
.Strategy interface to process operands of an operator call.Extension toSqlOperandTypeChecker
that also provides names and types of particular operands.Strategy interface to check for allowed operand types of an operator call.Strategy used to make arguments consistent.Strategy to infer unknown types of the operands of an operator call.Strategy interface to infer the type of an operator call from the type of the operands.Strategy to infer the type of an operator call from the type of the operands by using a series ofSqlReturnTypeInference
rules in a given order.SqlSingleOperandTypeChecker is an extension ofSqlOperandTypeChecker
for implementations which are capable of checking the type of a single operand in isolation.Rules that determine whether a type is assignable from another type.Rules that determine whether a type is castable from another type.SqlTypeExplicitPrecedenceList implements theRelDataTypePrecedenceList
interface via an explicit list ofSqlTypeName
entries.SqlTypeFactoryImpl provides a default implementation ofRelDataTypeFactory
which supports SQL types.SqlTypeFamily provides SQL type categorization.Interface that defines rules within type mappings.This class defines some utilities to build type mapping matrix which would then use to construct theSqlTypeMappingRule
rules.Keeps state while building the type mappings.Enumeration of the type names which can be used to construct a SQL type.Limit.Strategy to transform one type to another.Strategy to infer the type of an operator call from the type of the operands by using oneSqlReturnTypeInference
rule and a combination ofSqlTypeTransform
s.SqlTypeTransforms defines a number of reusable instances ofSqlTypeTransform
.Contains utility methods used during SQL validation or type derivation.TableFunctionReturnTypeInference implements rules for deriving table function output row types by expanding references to cursor parameters.