According to Teradata's document this error happened within RES modules during expression resolution, and it is adviced to "correct the condition and resubmit". However this seems doesn't fit to my situation so I have no idea how to improve the statement.
If I try to shorten the statement by concatenating only part of the columns, sometimes I got error:
"HY001-3710 [ODBC Teradata Driver] Insufficient memory to parse this request, during Optimizer phase."
My question are:
(1) How can I rewrite the SQL statement such that Teradata is happen to parse and execute?
(2) What is the limit for concatenating string in SQL? What is the limit for submiting such query to the database? Is it configurable or depends on hardware configuration?