问题
I have long query like this in the procedure
CREATE PROCEDURE procedure1(var type1)
DEFINE Result Type2;
LET c_query =
"SELECT " ||
"RESULT " ||
"FROM " ||
"QUERY_PART1 " ||
"join " ||
"QUERY_PART2 " ||
"join " ||
...
"END_PART ";
PREPARE c_stmt FROM c_query; -- Problematic line
DECLARE c_cur CURSOR FOR c_stmt;
OPEN c_cur;
....
END PROCEDURE
But the "PREPARE c_stmt FROM c_query;" line does not run , and the error is
Execute: A syntax error has occurred
I Try to find syntax error of Query, online, but didn't work. Can I find the line of Error?
Can anybody Help?
来源:https://stackoverflow.com/questions/64746385/informix-12-10-finding-the-error-point-in-the-query-when-the-statement-could-not