DSNH20441I E csect-name LINE line-number type-name TYPE IS NOT VALID WHERE SPECIFIED. REASON CODE reason-code.
Explanation
An array data type cannot be specified in the context in which it is used.
- type-name
- The name of the array type.
- reason-code
- A numeric value that indicates the reason that the statement cannot
be executed. Possible values are:
- 1
- An array data type was specified where an array type is not supported,
or a value that is not an array data type was specified where an array
value is required.
Some of the contexts in which an array data type is supported are:
- A parameter to an SQL function
- A return data type from an SQL function
- A Parameter to an SQL procedure
- An SQL variable that is declared in an SQL function
- An SQL variable that is declared in an SQL procedure
Some of the contexts in which an array data type is not supported are:
- A parameter or variable for an external routine
- A return type of an inline SQL function
- A column in a table
The UNNEST operator must be an array value. That array value must be one of the following items:
- An SQL variable
- An SQL parameter
- An array function invocation
- A CAST specification of a parameter marker to an array type
- 2
- A global variable was defined as a distinct type. A global variable cannot be defined as a distinct type.
System action
The statement cannot be processed.
Programmer response
See the documentation for the SQL statement on which the error occurred for a complete list of restrictions on the use of the array data type in that context. Change the SQL statement to use an array data type only in a context in which it is allowed.
Severity
8 (error)