Numeric overflow @recursive

General
asu
N/A

Numeric overflow @recursive

Hi,

By using below recursive with query I am try to find untranslatable characters of my string and eliminate them... But I could not see the part of code that cause numeric overflow.

any helps will be appreciated

WITH RECURSIVE recursive_T1
 (
  DCS_SRCROW,
  len,
  left_word,
  right_word,
  pos
 )
 AS (
  SELECT
    DCS_SRCROW,
    case when TRANSLATE_CHK (DCS_SRCROW USING LATIN_TO_UNICODE) = 0 then 1 else  TRANSLATE_CHK (DCS_SRCROW USING LATIN_TO_UNICODE) end  len,
    SUBSTRING(DCS_SRCROW FROM 1 FOR  len - 1 ) AS left_word,
    SUBSTRING(DCS_SRCROW FROM len+1) AS right_word,
    1 as pos
  FROM DD_DWHST.FT_DCS_PSGR_DETAIL_RAW_RJCT
  
  UNION ALL
  
  SELECT
   DCS_SRCROW,
   case when TRANSLATE_CHK( right_word USING LATIN_TO_UNICODE )  = 0 then 1 else  TRANSLATE_CHK( right_word USING LATIN_TO_UNICODE ) end   len_new,
    left_word || SUBSTRING(right_word FROM 1 FOR len_new - 1 ) as left_word,
    SUBSTRING(right_word FROM len_new + 1) as right_word,
    pos + 1 as pos
  FROM recursive_T1
  WHERE right_word <> ''
 )
SELECT *
FROM recursive_T1