Package org.apache.calcite.sql.type
Class InferTypes
java.lang.Object
org.apache.calcite.sql.type.InferTypes
Strategies for inferring operand types.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final SqlOperandTypeInference
Operand type-inference strategy where an unknown operand type is assumed to be nullable ANY.static final SqlOperandTypeInference
Operand type-inference strategy where an unknown operand type is assumed to be boolean.static final SqlOperandTypeInference
Operand type-inference strategy where an unknown operand type is derived from the first operand with a known type.static final SqlOperandTypeInference
Operand type-inference strategy where an unknown operand type is derived from the call's return type.static final SqlOperandTypeInference
Operand type-inference strategy where an unknown operand type is assumed to be VARCHAR(1024). -
Method Summary
Modifier and TypeMethodDescriptionstatic SqlOperandTypeInference
explicit
(List<RelDataType> types) Returns anSqlOperandTypeInference
that returns a given list of types.
-
Field Details
-
FIRST_KNOWN
Operand type-inference strategy where an unknown operand type is derived from the first operand with a known type. -
RETURN_TYPE
Operand type-inference strategy where an unknown operand type is derived from the call's return type. If the return type is a record, it must have the same number of fields as the number of operands. -
BOOLEAN
Operand type-inference strategy where an unknown operand type is assumed to be boolean. -
VARCHAR_1024
Operand type-inference strategy where an unknown operand type is assumed to be VARCHAR(1024). This is not something which should be used in most cases (especially since the precision is arbitrary), but for IS [NOT] NULL, we don't really care about the type at all, so it's reasonable to use something that every other type can be cast to. -
ANY_NULLABLE
Operand type-inference strategy where an unknown operand type is assumed to be nullable ANY.
-
-
Method Details
-
explicit
Returns anSqlOperandTypeInference
that returns a given list of types.
-