DATATYPE_MISMATCH error class
Cannot resolve <sqlExpr>
due to data type mismatch:
ARRAY_FUNCTION_DIFF_TYPES
Input to <functionName>
should have been <dataType>
followed by a value with same element type, but it’s [<leftType>
, <rightType>
].
BINARY_ARRAY_DIFF_TYPES
Input to function <functionName>
should have been two <arrayType>
with same element type, but it’s [<leftType>
, <rightType>
].
BINARY_OP_DIFF_TYPES
the left and right operands of the binary operator have incompatible types (<left>
and <right>
).
BLOOM_FILTER_BINARY_OP_WRONG_TYPE
The Bloom filter binary input to <functionName>
should be either a constant value or a scalar subquery expression, but it’s <actual>
.
BLOOM_FILTER_WRONG_TYPE
Input to function <functionName>
should have been <expectedLeft>
followed by value with <expectedRight>
, but it’s [<actual>
].
CAST_TO_NAMED_PARAMETER
The function <functionName>
parameter <parameterName>
at position <pos>
requires <requiredType>
. The argument given is <argumentType>
.
CAST_WITH_CONF_SUGGESTION
cannot cast <srcType>
to <targetType>
with ANSI mode on.
If you have to cast <srcType>
to <targetType>
, you can set <config>
as <configVal>
.
CAST_WITH_FUNC_SUGGESTION
cannot cast <srcType>
to <targetType>
.
To convert values from <srcType>
to <targetType>
, you can use the functions <functionNames>
instead.
CREATE_MAP_KEY_DIFF_TYPES
The given keys of function <functionName>
should all be the same type, but they are <dataType>
.
CREATE_MAP_VALUE_DIFF_TYPES
The given values of function <functionName>
should all be the same type, but they are <dataType>
.
CREATE_NAMED_STRUCT_WITHOUT_FOLDABLE_STRING
Only foldable STRING
expressions are allowed to appear at odd position, but they are <inputExprs>
.
HASH_MAP_TYPE
Input to the function <functionName>
cannot contain elements of the “MAP
” type. In Spark, same maps may have different hashcode, thus hash expressions are prohibited on “MAP
” elements. To restore previous behavior set “spark.sql.legacy.allowHashOnMapType” to “true”.
HASH_VARIANT_TYPE
Input to the function <functionName>
cannot contain elements of the “VARIANT” type yet.
INVALID_ARG_VALUE
The <inputName>
value must to be a <requireType>
literal of <validValues>
, but got <inputValue>
.
INVALID_SECRET
The parameter value of the “apiKey” argument to the ai_generate_text function can not be a constant <inputExpr>
. Recommended usages include secret(scope, key)
function or a SELECT ...
subquery.
IN_SUBQUERY_DATA_TYPE_MISMATCH
The data type of one or more elements in the left hand side of an IN subquery is not compatible with the data type of the output of the subquery. Mismatched columns: [<mismatchedColumns>
], left side: [<leftType>
], right side: [<rightType>
].
IN_SUBQUERY_LENGTH_MISMATCH
The number of columns in the left hand side of an IN subquery does not match the number of columns in the output of subquery. Left hand side columns(length: <leftLength>
): [<leftColumns>
], right hand side columns(length: <rightLength>
): [<rightColumns>
].
MAP_FUNCTION_DIFF_TYPES
Input to <functionName>
should have been <dataType>
followed by a value with same key type, but it’s [<leftType>
, <rightType>
].
MAP_ZIP_WITH_DIFF_TYPES
Input to the <functionName>
should have been two maps with compatible key types, but it’s [<leftType>
, <rightType>
].
NON_FOLDABLE_INPUT
the input <inputName>
should be a foldable <inputType>
expression; however, got <inputExpr>
.
PARAMETER_CONSTRAINT_VIOLATION
The <leftExprName>
(<leftExprValue>
) must be <constraint>
the <rightExprName>
(<rightExprValue>
).
RANGE_FRAME_INVALID_TYPE
The data type <orderSpecType>
used in the order specification does not match the data type <valueBoundaryType>
which is used in the range frame.
RANGE_FRAME_MULTI_ORDER
A range window frame with value boundaries cannot be used in a window specification with multiple order by expressions: <orderSpec>
.
REMOTE_FUNCTION_INVALID_REMOTE_URL
The input parameter: <paramName>
, value: <paramValue>
can not be used to construct a valid remote URL because <reason>
REMOTE_FUNCTION_WRONG_PARAMETER_NAMES
The input parameter names are not correct. Missing required parameters: <missingValues>
, unrecognized parameters: <unknownValues>
.
SEQUENCE_WRONG_INPUT_TYPES
<functionName>
uses the wrong parameter type. The parameter type must conform to:
The start and stop expressions must resolve to the same type.
If start and stop expressions resolve to the
<startType>
type, then the step expression must resolve to the<stepType>
type.Otherwise, if start and stop expressions resolve to the
<otherStartType>
type, then the step expression must resolve to the same type.
SPECIFIED_WINDOW_FRAME_DIFF_TYPES
Window frame bounds <lower>
and <upper>
do not have the same type: <lowerType>
<> <upperType>
.
SPECIFIED_WINDOW_FRAME_INVALID_BOUND
Window frame upper bound <upper>
does not follow the lower bound <lower>
.
SPECIFIED_WINDOW_FRAME_UNACCEPTED_TYPE
The data type of the <location>
bound <exprType>
does not match the expected data type <expectedType>
.
SPECIFIED_WINDOW_FRAME_WITHOUT_FOLDABLE
Window frame <location>
bound <expression>
is not a literal.
SPECIFIED_WINDOW_FRAME_WRONG_COMPARISON
The lower bound of a window frame must be <comparison>
to the upper bound.
STACK_COLUMN_DIFF_TYPES
The data type of the column (<columnIndex>
) do not have the same type: <leftType>
(<leftParamIndex>
) <> <rightType>
(<rightParamIndex>
).
UNEXPECTED_INPUT_TYPE
The <paramIndex>
parameter requires the <requiredType>
type, however <inputSql>
has the type <inputType>
.
UNEXPECTED_RETURN_TYPE
The <functionName>
requires return <expectedType>
type, but the actual is <actualType>
type.
UNEXPECTED_STATIC_METHOD
cannot find a static method <methodName>
that matches the argument types in <className>
.