| |
- Causa
- THE USE OF FUNCTION function-name IS INVALID BECAUSE IT IS NOT DETERMINISTIC OR HAS AN EXTERNAL ACTION
The function function-name is defined as a not deterministic function or a function with an external action.
This type of function is not supported in the context in which it is used.
The contexts in which these are not valid are:
- in the expression prior to the first WHEN keyword in a simple-case-expression.
- in the WHERE clause of the subselect in a CREATE VIEW statement if the WITH CHECK OPTION is specified.
- in an expression of an ORDER BY clause
- Ação do sistema
- The statement cannot be executed.
- Resposta ao Desenvolvedor
- If the use of a not deterministic or external action function was not intended, substitute a function without these characteristics.
If the behavior associated with the not deterministic or external action function is intentional, use the alternate form of the statements that
make that intent explicit.
- Instead of a simple-when-clause, use the corresponding searched-when-clause where the function would get specified in each search-condition.
- Remove the WITH CHECK OPTION from the CREATE VIEW statement.
- Remove the function from the ORDER BY clause.
If the column is part of the result set of the query, change the expression in the ORDER BY clause to the simple-integer or
simple-column-name form of the sort key.
See the ORDER BY syntax diagram in the DB2 SQL Reference for more information.
SQLSTATE: 42845
© Copyright IBM Corp.
|
| |