Archives of the TeradataForum
Message Posted: Thu, 15 Sep 2005 @ 09:50:08 GMT
When I am using user defined function in CASE statement along with NOT EXISTS clause teradata gives strange error 3610. Where as this same function used with different combination i.e. either one, NOT EXISTS or CASE statement, if not used, it works.
Below I have pasted the query as well as error, where 'lpad' is the function which simulates Oracle's 'LPAD'.
There is no problem with the UDF. It works very well.
This behaviour I am finding only, when UDF is used in 'CASE' which is within 'NOT EXISTS' clause.
Can anybody justify ?
SELECT * FROM taoa WHERE NOT EXISTS ( SELECT 1 FROM tas01 WHERE taoa.oan = CASE WHEN taoa.appli_cd = '80' THEN ( lpad( COALESCE( CAST( CAST( tas01.pinsuper AS INTEGER) AS VARCHAR(5) ), '' ), 5, '0') ) || ( COALESCE( tas01.pintycon, '' ) ) ELSE '90000' || ( COALESCE( tas01.pintycon, '' ) ) END ) --------------------------- *** Failure 3610 Internal error: Please do not resubmit the last request. Statement# 1, Info =118 *** Total elapsed time was 2 seconds. *** Warning: Last request caused a problem on the DBC. Do NOT resubmit the last request.
|Copyright 2016 - All Rights Reserved|
|Last Modified: 27 Dec 2016|