Package dev.frostlake.executor
Enum Class TableFunctionParameterKind
- All Implemented Interfaces:
Serializable,Comparable<TableFunctionParameterKind>,Constable
What a table function's parameter will take. Snowflake type-checks these at COMPILE time and names
the offending type in the refusal —
FLATTEN(INPUT => '[1,2,3]') is
invalid type [VARCHAR(7)] for parameter 'INPUT', not a silent coercion of the JSON text.
Each kind lists only the families measured to be REFUSED. A type this enum does not recognise is accepted, so an expression whose type cannot be determined statically can never be rejected here.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionBOOLEAN.VARIANT, OBJECT or ARRAY.VARCHAR —FLATTEN(…, PATH => 1)isinvalid type [NUMBER(1,0)] for parameter 'PATH'.TIMESTAMP. -
Method Summary
Modifier and TypeMethodDescriptionstatic TableFunctionParameterKindReturns the enum constant of this class with the specified name.static TableFunctionParameterKind[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
SEMI_STRUCTURED
VARIANT, OBJECT or ARRAY. Live refuses VARCHAR, NUMBER, BOOLEAN and DATE alike, so a JSON string has to be parsed (PARSE_JSON) or cast before FLATTEN will look at it. -
STRING
VARCHAR —FLATTEN(…, PATH => 1)isinvalid type [NUMBER(1,0)] for parameter 'PATH'. -
TIMESTAMP
TIMESTAMP. The history functions' leading positional parameters are time-range bounds, soQUERY_HISTORY(2)isinvalid type [NUMBER(1,0)] for parameter 'END_TIME_RANGE_START'— and so is a date-shaped STRING, which is not implicitly converted. -
BOOLEAN
BOOLEAN. The string'TRUE'does NOT count: live answersinvalid type [VARCHAR(4)] for parameter 'OUTER', so the flags take a boolean literal.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-