Class ReturnTypes

java.lang.Object
org.apache.calcite.sql.type.ReturnTypes

public abstract class ReturnTypes extends Object
A collection of return-type inference strategies.
  • Field Details

    • ARG0

      public static final SqlReturnTypeInference ARG0
      Type-inference strategy whereby the result type of a call is the type of the operand #0 (0-based).
    • ARG0_NULLABLE_VARYING

      public static final SqlReturnTypeInference ARG0_NULLABLE_VARYING
      Type-inference strategy whereby the result type of a call is VARYING the type of the first argument. The length returned is the same as length of the first argument. If any of the other operands are nullable the returned type will also be nullable. First Arg must be of string type.
    • ARG0_NULLABLE

      public static final SqlReturnTypeInference ARG0_NULLABLE
      Type-inference strategy whereby the result type of a call is the type of the operand #0 (0-based). If any of the other operands are nullable the returned type will also be nullable.
    • ARG0_NULLABLE_IF_ARG0_NULLABLE

      public static final SqlReturnTypeInference ARG0_NULLABLE_IF_ARG0_NULLABLE
      Type-inference strategy whereby the result type of a call is the type of the operand #0 (0-based). If the operand #0 (0-based) is nullable, the returned type will also be nullable.
    • ARG0_FORCE_NULLABLE

      public static final SqlReturnTypeInference ARG0_FORCE_NULLABLE
      Type-inference strategy whereby the result type of a call is the type of the operand #0 (0-based), with nulls always allowed.
    • ARG0_INTERVAL

      public static final SqlReturnTypeInference ARG0_INTERVAL
    • ARG0_INTERVAL_NULLABLE

      public static final SqlReturnTypeInference ARG0_INTERVAL_NULLABLE
    • ARG0_NULLABLE_IF_EMPTY

      public static final SqlReturnTypeInference ARG0_NULLABLE_IF_EMPTY
      Type-inference strategy whereby the result type of a call is the type of the operand #0 (0-based), and nullable if the call occurs within a "GROUP BY ()" query. E.g. in "select sum(1) as s from empty", s may be null.
    • ARG1

      public static final SqlReturnTypeInference ARG1
      Type-inference strategy whereby the result type of a call is the type of the operand #1 (0-based).
    • ARG1_NULLABLE

      public static final SqlReturnTypeInference ARG1_NULLABLE
      Type-inference strategy whereby the result type of a call is the type of the operand #1 (0-based). If any of the other operands are nullable the returned type will also be nullable.
    • ARG2

      public static final SqlReturnTypeInference ARG2
      Type-inference strategy whereby the result type of a call is the type of operand #2 (0-based).
    • ARG2_NULLABLE

      public static final SqlReturnTypeInference ARG2_NULLABLE
      Type-inference strategy whereby the result type of a call is the type of operand #2 (0-based). If any of the other operands are nullable the returned type will also be nullable.
    • BOOLEAN

      public static final SqlReturnTypeInference BOOLEAN
      Type-inference strategy whereby the result type of a call is Boolean.
    • BOOLEAN_NULLABLE

      public static final SqlReturnTypeInference BOOLEAN_NULLABLE
      Type-inference strategy whereby the result type of a call is Boolean, with nulls allowed if any of the operands allow nulls.
    • BOOLEAN_NULLABLE_IF_ARG0_NULLABLE

      public static final SqlReturnTypeInference BOOLEAN_NULLABLE_IF_ARG0_NULLABLE
      Type-inference strategy whereby the result type of a call is Boolean, with nulls allowed if the type of the operand #0 (0-based) is nullable.
    • BOOLEAN_NULLABLE_OPTIMIZED

      public static final SqlReturnTypeInference BOOLEAN_NULLABLE_OPTIMIZED
      Type-inference strategy with similar effect to BOOLEAN_NULLABLE, which is more efficient, but can only be used if all arguments are BOOLEAN.
    • BOOLEAN_FORCE_NULLABLE

      public static final SqlReturnTypeInference BOOLEAN_FORCE_NULLABLE
      Type-inference strategy whereby the result type of a call is a nullable Boolean.
    • BOOLEAN_NOT_NULL

      public static final SqlReturnTypeInference BOOLEAN_NOT_NULL
      Type-inference strategy whereby the result type of a call is BOOLEAN NOT NULL.
    • DATE

      public static final SqlReturnTypeInference DATE
      Type-inference strategy whereby the result type of a call is DATE.
    • DATE_NULLABLE

      public static final SqlReturnTypeInference DATE_NULLABLE
      Type-inference strategy whereby the result type of a call is nullable DATE.
    • ARG0_EXCEPT_DATE

      public static final SqlReturnTypeInference ARG0_EXCEPT_DATE
      Type-inference strategy that returns the type of the first operand, unless it is a DATE, in which case the return type is TIMESTAMP. Supports cases such as [CALCITE-5757] Incorrect return type for BigQuery TRUNC functions .
    • ARG0_EXCEPT_DATE_NULLABLE

      public static final SqlReturnTypeInference ARG0_EXCEPT_DATE_NULLABLE
      Same as ARG0_EXCEPT_DATE but returns with nullability if any of the operands is nullable by using SqlTypeTransforms.TO_NULLABLE.
    • TIME

      public static final SqlReturnTypeInference TIME
      Type-inference strategy whereby the result type of a call is TIME(0).
    • TIME_NULLABLE

      public static final SqlReturnTypeInference TIME_NULLABLE
      Type-inference strategy whereby the result type of a call is nullable TIME(0).
    • TIMESTAMP

      public static final SqlReturnTypeInference TIMESTAMP
      Type-inference strategy whereby the result type of a call is TIMESTAMP.
    • TIMESTAMP_NULLABLE

      public static final SqlReturnTypeInference TIMESTAMP_NULLABLE
      Type-inference strategy whereby the result type of a call is nullable TIMESTAMP.
    • TIMESTAMP_LTZ

      public static final SqlReturnTypeInference TIMESTAMP_LTZ
      Type-inference strategy whereby the result type of a call is TIMESTAMP WITH LOCAL TIME ZONE.
    • TIMESTAMP_TZ

      public static final SqlReturnTypeInference TIMESTAMP_TZ
      Type-inference strategy whereby the result type of a call is TIMESTAMP WITH TIME ZONE.
    • TIMESTAMP_LTZ_NULLABLE

      public static final SqlReturnTypeInference TIMESTAMP_LTZ_NULLABLE
      Type-inference strategy whereby the result type of a call is nullable TIMESTAMP WITH LOCAL TIME ZONE.
    • DOUBLE

      public static final SqlReturnTypeInference DOUBLE
      Type-inference strategy whereby the result type of a call is Double.
    • DOUBLE_NULLABLE

      public static final SqlReturnTypeInference DOUBLE_NULLABLE
      Type-inference strategy whereby the result type of a call is Double with nulls allowed if any of the operands allow nulls.
    • DOUBLE_FORCE_NULLABLE

      public static final SqlReturnTypeInference DOUBLE_FORCE_NULLABLE
      Type-inference strategy whereby the result type of a call is a nullable Double.
    • CHAR

      public static final SqlReturnTypeInference CHAR
      Type-inference strategy whereby the result type of a call is a Char.
    • CHAR_FORCE_NULLABLE

      public static final SqlReturnTypeInference CHAR_FORCE_NULLABLE
      Type-inference strategy whereby the result type of a call is a nullable CHAR(1).
    • TINYINT

      public static final SqlReturnTypeInference TINYINT
      Type-inference strategy whereby the result type of a call is a TINYINT.
    • TINYINT_NULLABLE

      public static final SqlReturnTypeInference TINYINT_NULLABLE
      Type-inference strategy whereby the result type of a call is a TINYINT with nulls allowed if any of the operands allow nulls.
    • INTEGER

      public static final SqlReturnTypeInference INTEGER
      Type-inference strategy whereby the result type of a call is an Integer.
    • INTEGER_NULLABLE

      public static final SqlReturnTypeInference INTEGER_NULLABLE
      Type-inference strategy whereby the result type of a call is an Integer with nulls allowed if any of the operands allow nulls.
    • BIGINT

      public static final SqlReturnTypeInference BIGINT
      Type-inference strategy whereby the result type of a call is a BIGINT.
    • BIGINT_FORCE_NULLABLE

      public static final SqlReturnTypeInference BIGINT_FORCE_NULLABLE
      Type-inference strategy whereby the result type of a call is a nullable BIGINT.
    • BIGINT_NULLABLE

      public static final SqlReturnTypeInference BIGINT_NULLABLE
      Type-inference strategy whereby the result type of a call is a BIGINT with nulls allowed if any of the operands allow nulls.
    • VARCHAR_4

      public static final SqlReturnTypeInference VARCHAR_4
      Type-inference strategy that always returns "VARCHAR(4)".
    • VARCHAR_4_NULLABLE

      public static final SqlReturnTypeInference VARCHAR_4_NULLABLE
      Type-inference strategy that always returns "VARCHAR(4)" with nulls allowed if any of the operands allow nulls.
    • VARCHAR_2000

      public static final SqlReturnTypeInference VARCHAR_2000
      Type-inference strategy that always returns "VARCHAR(2000)".
    • VARCHAR_2000_NULLABLE

      public static final SqlReturnTypeInference VARCHAR_2000_NULLABLE
      Type-inference strategy that always returns "VARCHAR(2000)" with nulls allowed if any of the operands allow nulls.
    • VARCHAR

      public static final SqlReturnTypeInference VARCHAR
      Type-inference strategy that always returns "VARCHAR".
    • VARCHAR_NULLABLE

      public static final SqlReturnTypeInference VARCHAR_NULLABLE
      Type-inference strategy that always returns "VARCHAR" with nulls allowed if any of the operands allow nulls.
    • VARBINARY

      public static final SqlReturnTypeInference VARBINARY
      Type-inference strategy that always returns "VARBINARY".
    • VARBINARY_NULLABLE

      public static final SqlReturnTypeInference VARBINARY_NULLABLE
      Type-inference strategy that always returns "VARBINARY" with nulls allowed if any of the operands allow nulls.
    • HISTOGRAM

      public static final SqlReturnTypeInference HISTOGRAM
      Type-inference strategy for Histogram agg support.
    • CURSOR

      public static final SqlReturnTypeInference CURSOR
      Type-inference strategy that always returns "CURSOR".
    • COLUMN_LIST

      public static final SqlReturnTypeInference COLUMN_LIST
      Type-inference strategy that always returns "COLUMN_LIST".
    • LEAST_RESTRICTIVE

      public static final SqlReturnTypeInference LEAST_RESTRICTIVE
      Type-inference strategy whereby the result type of a call is using its operands biggest type, using the SQL:1999 rules described in "Data types of results of aggregations". These rules are used in union, except, intersect, case and other places.
      See Also:
    • ARG0_EXCEPT_INTEGER

      public static final SqlReturnTypeInference ARG0_EXCEPT_INTEGER
      Type-inference strategy that returns the type of the first operand, unless it is an integer type, in which case the return type is DOUBLE.
    • ARG0_EXCEPT_INTEGER_NULLABLE

      public static final SqlReturnTypeInference ARG0_EXCEPT_INTEGER_NULLABLE
      Same as ARG0_EXCEPT_INTEGER but returns with nullability if any of the operands is nullable by using SqlTypeTransforms.TO_NULLABLE.
    • MULTISET

      public static final SqlReturnTypeInference MULTISET
      Returns the same type as the multiset carries. The multiset type returned is the least restrictive of the call's multiset operands
    • TO_COLLECTION_ELEMENT

      public static final SqlReturnTypeInference TO_COLLECTION_ELEMENT
      Returns the element type of an ARRAY or MULTISET.

      For example, given INTEGER ARRAY or MULTISET ARRAY, returns INTEGER.

    • TO_COLLECTION_ELEMENT_NULLABLE

      public static final SqlReturnTypeInference TO_COLLECTION_ELEMENT_NULLABLE
    • TO_COLLECTION_ELEMENT_FORCE_NULLABLE

      public static final SqlReturnTypeInference TO_COLLECTION_ELEMENT_FORCE_NULLABLE
    • TO_MULTISET

      public static final SqlReturnTypeInference TO_MULTISET
      Returns a MULTISET type.

      For example, given INTEGER, returns INTEGER MULTISET.

    • MULTISET_ELEMENT_FORCE_NULLABLE

      public static final SqlReturnTypeInference MULTISET_ELEMENT_FORCE_NULLABLE
      Returns the element type of a MULTISET, with nullability enforced.
    • MULTISET_NULLABLE

      public static final SqlReturnTypeInference MULTISET_NULLABLE
      Same as MULTISET but returns with nullability if any of the operands is nullable.
    • MULTISET_PROJECT_ONLY

      public static final SqlReturnTypeInference MULTISET_PROJECT_ONLY
      Returns the type of the only column of a multiset.

      For example, given RECORD(x INTEGER) MULTISET, returns INTEGER MULTISET.

    • TO_ARRAY

      public static final SqlReturnTypeInference TO_ARRAY
      Returns an ARRAY type.

      For example, given INTEGER, returns INTEGER ARRAY.

    • TO_MAP

      public static final SqlReturnTypeInference TO_MAP
      Returns a MAP type.

      For example, given Record(f0: INTEGER, f1: DATE), returns (INTEGER, DATE) MAP.

    • IDENTITY_TO_MAP

      public static final SqlReturnTypeInference IDENTITY_TO_MAP
      Returns a MAP type.

      For example, given STRING, returns (STRING, STRING) MAP.

    • IDENTITY_TO_MAP_NULLABLE

      public static final SqlReturnTypeInference IDENTITY_TO_MAP_NULLABLE
      Same as IDENTITY_TO_MAP but returns with nullability if any of the operands is nullable.
    • TO_ROW

      public static final SqlReturnTypeInference TO_ROW
      Returns a ROW type.

      For example, given (INTEGER, DATE) MAP, returns Record(f0: INTEGER, f1: DATE).

    • TO_MAP_ENTRIES

      public static final SqlReturnTypeInference TO_MAP_ENTRIES
      Returns a ARRAY type.

      For example, given (INTEGER, DATE) MAP, returns Record(f0: INTEGER, f1: DATE) ARRAY.

    • TO_MAP_ENTRIES_NULLABLE

      public static final SqlReturnTypeInference TO_MAP_ENTRIES_NULLABLE
    • TO_MAP_KEYS

      public static final SqlReturnTypeInference TO_MAP_KEYS
      Returns a ARRAY type.

      For example, given (INTEGER, DATE) MAP, returns INTEGER ARRAY.

    • TO_MAP_KEYS_NULLABLE

      public static final SqlReturnTypeInference TO_MAP_KEYS_NULLABLE
    • TO_MAP_VALUES

      public static final SqlReturnTypeInference TO_MAP_VALUES
      Returns a ARRAY type.

      For example, given (INTEGER, DATE) MAP, returns DATE ARRAY.

    • TO_MAP_VALUES_NULLABLE

      public static final SqlReturnTypeInference TO_MAP_VALUES_NULLABLE
    • GEOMETRY

      public static final SqlReturnTypeInference GEOMETRY
      Type-inference strategy that always returns GEOMETRY.
    • INTEGER_QUOTIENT_NULLABLE

      public static final SqlReturnTypeInference INTEGER_QUOTIENT_NULLABLE
      Type-inference strategy whereby the result type of a call is ARG0_INTERVAL_NULLABLE and LEAST_RESTRICTIVE. These rules are used for integer division.
    • DECIMAL_SCALE0

      public static final SqlReturnTypeInference DECIMAL_SCALE0
      Type-inference strategy for a call where the first argument is a decimal. The result type of a call is a decimal with a scale of 0, and the same precision and nullability as the first argument.
    • ARG0_OR_EXACT_NO_SCALE

      public static final SqlReturnTypeInference ARG0_OR_EXACT_NO_SCALE
      Type-inference strategy whereby the result type of a call is DECIMAL_SCALE0 with a fallback to ARG0 This rule is used for floor, ceiling.
    • DECIMAL_PRODUCT

      public static final SqlReturnTypeInference DECIMAL_PRODUCT
      Type-inference strategy whereby the result type of a call is the decimal product of two exact numeric operands where at least one of the operands is a decimal.
    • DECIMAL_PRODUCT_NULLABLE

      public static final SqlReturnTypeInference DECIMAL_PRODUCT_NULLABLE
      Same as DECIMAL_PRODUCT but returns with nullability if any of the operands is nullable by using SqlTypeTransforms.TO_NULLABLE.
    • PRODUCT_FORCE_NULLABLE

      public static final SqlReturnTypeInference PRODUCT_FORCE_NULLABLE
      Same as DECIMAL_PRODUCT_NULLABLE but returns with nullability if any of the operands is nullable or the operation results in overflow by using SqlTypeTransforms.FORCE_NULLABLE. Also handles multiplication for integers, not just decimals.
    • PRODUCT_NULLABLE

      public static final SqlReturnTypeInference PRODUCT_NULLABLE
      Type-inference strategy whereby the result type of a call is DECIMAL_PRODUCT_NULLABLE with a fallback to ARG0_INTERVAL_NULLABLE and LEAST_RESTRICTIVE. These rules are used for multiplication.
    • DECIMAL_QUOTIENT

      public static final SqlReturnTypeInference DECIMAL_QUOTIENT
      Type-inference strategy whereby the result type of a call is the decimal quotient of two exact numeric operands where at least one of the operands is a decimal.
    • DECIMAL_QUOTIENT_NULLABLE

      public static final SqlReturnTypeInference DECIMAL_QUOTIENT_NULLABLE
      Same as DECIMAL_QUOTIENT but returns with nullability if any of the operands is nullable by using SqlTypeTransforms.TO_NULLABLE.
    • DOUBLE_IF_INTEGERS

      public static final SqlReturnTypeInference DOUBLE_IF_INTEGERS
      Type-inference strategy whereby the result type of a call is DOUBLE if both operands are integer types.
    • QUOTIENT_FORCE_NULLABLE

      public static final SqlReturnTypeInference QUOTIENT_FORCE_NULLABLE
      Same as DECIMAL_QUOTIENT_NULLABLE but returns with nullability if any of the operands is nullable or the operation results in overflow by using SqlTypeTransforms.FORCE_NULLABLE. Also handles multiplication for integers, not just decimals.
    • QUOTIENT_NULLABLE

      public static final SqlReturnTypeInference QUOTIENT_NULLABLE
      Type-inference strategy whereby the result type of a call is DECIMAL_QUOTIENT_NULLABLE with a fallback to ARG0_INTERVAL_NULLABLE and LEAST_RESTRICTIVE. These rules are used for division.
    • DECIMAL_SUM

      public static final SqlReturnTypeInference DECIMAL_SUM
      Type-inference strategy whereby the result type of a call is the decimal sum of two exact numeric operands where at least one of the operands is a decimal.
    • DECIMAL_SUM_NULLABLE

      public static final SqlReturnTypeInference DECIMAL_SUM_NULLABLE
      Same as DECIMAL_SUM but returns with nullability if any of the operands is nullable by using SqlTypeTransforms.TO_NULLABLE.
    • SUM_FORCE_NULLABLE

      public static final SqlReturnTypeInference SUM_FORCE_NULLABLE
      Same as DECIMAL_SUM_NULLABLE but returns with nullability if any of the operands is nullable or the operation results in overflow by using SqlTypeTransforms.FORCE_NULLABLE. Also handles addition for integers, not just decimals.
    • NULLABLE_SUM

      public static final SqlReturnTypeInference NULLABLE_SUM
      Type-inference strategy whereby the result type of a call is DECIMAL_SUM_NULLABLE with a fallback to LEAST_RESTRICTIVE These rules are used for addition and subtraction.
    • DECIMAL_MOD

      public static final SqlReturnTypeInference DECIMAL_MOD
    • DECIMAL_MOD_NULLABLE

      public static final SqlReturnTypeInference DECIMAL_MOD_NULLABLE
      Type-inference strategy whereby the result type of a call is the decimal modulus of two exact numeric operands where at least one of the operands is a decimal.
    • NULLABLE_MOD

      public static final SqlReturnTypeInference NULLABLE_MOD
      Type-inference strategy whereby the result type of a call is DECIMAL_MOD_NULLABLE with a fallback to ARG1_NULLABLE These rules are used for modulus.
    • DYADIC_STRING_SUM_PRECISION

      public static final SqlReturnTypeInference DYADIC_STRING_SUM_PRECISION
      Type-inference strategy for concatenating two string arguments. The result type of a call is:
      • the same type as the input types but with the combined length of the two first types
      • if types are of char type the type with the highest coercibility will be used
      • result is varying if either input is; otherwise fixed

      Pre-requisites:

      • input types must be of the same string type
      • types must be comparable without casting
    • MULTIVALENT_STRING_SUM_PRECISION

      public static final SqlReturnTypeInference MULTIVALENT_STRING_SUM_PRECISION
      Type-inference strategy for String concatenation. Result is varying if either input is; otherwise fixed. For example,

      concat(cast('a' as varchar(2)), cast('b' as varchar(3)),cast('c' as varchar(2))) returns varchar(7).

      concat(cast('a' as varchar), cast('b' as varchar(2)), cast('c' as varchar(2))) returns varchar.

      concat(cast('a' as varchar(65535)), cast('b' as varchar(2)), cast('c' as varchar(2))) returns varchar.

    • MULTIVALENT_STRING_WITH_SEP_SUM_PRECISION

      public static final SqlReturnTypeInference MULTIVALENT_STRING_WITH_SEP_SUM_PRECISION
      Type-inference strategy for String concatenation with separator. The precision of separator should be calculated during combining. Result is varying if either input is; otherwise fixed.

      For example:

      • concat_ws(',', cast('a' as varchar(2), cast('b' as varchar(3)), cast('c' as varchar(2))) returns varchar(9);
      • concat_ws(',', cast('a' as varchar), cast('b' as varchar(2)), cast('c' as varchar(2))) returns varchar;
      • concat_ws(',', cast('a' as varchar(65535)), cast('b' as varchar(2)), cast('c' as varchar(2))) returns varchar.
    • MULTIVALENT_STRING_SUM_PRECISION_NULLABLE

      public static final SqlReturnTypeInference MULTIVALENT_STRING_SUM_PRECISION_NULLABLE
    • MULTIVALENT_STRING_SUM_PRECISION_NOT_NULLABLE

      public static final SqlReturnTypeInference MULTIVALENT_STRING_SUM_PRECISION_NOT_NULLABLE
    • MULTIVALENT_STRING_WITH_SEP_SUM_PRECISION_NOT_NULLABLE

      public static final SqlReturnTypeInference MULTIVALENT_STRING_WITH_SEP_SUM_PRECISION_NOT_NULLABLE
    • MULTIVALENT_STRING_WITH_SEP_SUM_PRECISION_ARG0_NULLABLE

      public static final SqlReturnTypeInference MULTIVALENT_STRING_WITH_SEP_SUM_PRECISION_ARG0_NULLABLE
    • MULTIVALENT_STRING_SUM_PRECISION_NULLABLE_ALL

      public static final SqlReturnTypeInference MULTIVALENT_STRING_SUM_PRECISION_NULLABLE_ALL
    • DYADIC_STRING_SUM_PRECISION_NULLABLE_VARYING

      public static final SqlReturnTypeInference DYADIC_STRING_SUM_PRECISION_NULLABLE_VARYING
    • DYADIC_STRING_SUM_PRECISION_NULLABLE

      public static final SqlReturnTypeInference DYADIC_STRING_SUM_PRECISION_NULLABLE
    • SCOPE

      public static final SqlReturnTypeInference SCOPE
      Type-inference strategy where the expression is assumed to be registered as a SqlValidatorNamespace, and therefore the result type of the call is the type of that namespace.
    • MULTISET_PROJECT0

      public static final SqlReturnTypeInference MULTISET_PROJECT0
      Returns a multiset of column #0 of a multiset. For example, given RECORD(x INTEGER, y DATE) MULTISET, returns INTEGER MULTISET.
    • MULTISET_RECORD

      public static final SqlReturnTypeInference MULTISET_RECORD
      Returns a multiset of the first column of a multiset. For example, given INTEGER MULTISET, returns RECORD(x INTEGER) MULTISET.
    • RECORD_TO_SCALAR

      public static final SqlReturnTypeInference RECORD_TO_SCALAR
      Returns the field type of a structured type which has only one field. For example, given RECORD(x INTEGER) returns INTEGER.
    • AGG_SUM

      public static final SqlReturnTypeInference AGG_SUM
      Type-inference strategy for SUM aggregate function inferred from the operand type, and nullable if the call occurs within a "GROUP BY ()" query. E.g. in "select sum(x) as s from empty", s may be null. Also, with the default implementation of RelDataTypeSystem, s has the same type name as x.
    • AGG_SUM_EMPTY_IS_ZERO

      public static final SqlReturnTypeInference AGG_SUM_EMPTY_IS_ZERO
      Type-inference strategy for $SUM0 aggregate function inferred from the operand type. By default the inferred type is identical to the operand type. E.g. in "select $sum0(x) as s from empty", s has the same type as x.
    • FRACTIONAL_RANK

      public static final SqlReturnTypeInference FRACTIONAL_RANK
      Type-inference strategy for the CUME_DIST and PERCENT_RANK aggregate functions.
    • RANK

      public static final SqlReturnTypeInference RANK
      Type-inference strategy for the NTILE, RANK, DENSE_RANK, and ROW_NUMBER aggregate functions.
    • AVG_AGG_FUNCTION

      public static final SqlReturnTypeInference AVG_AGG_FUNCTION
    • COVAR_REGR_FUNCTION

      public static final SqlReturnTypeInference COVAR_REGR_FUNCTION
    • PERCENTILE_DISC_CONT

      public static final SqlReturnTypeInference PERCENTILE_DISC_CONT
  • Method Details