I'm trying to create and use a global temporary table in RPG IV. The compiler has no problem with my DECLARE statement, but when I try to reference it in the following SQL UPDATE statement, the compiler complains about not having any column definitions (SQL1103). The temporary table is created using the "AS" clause.
Do I need to change the DECLARE......AS (SELECT....) WITH DATA to a regular DECLARE with column definitions followed by an INSERT statement (to load the table)? Or, since the table is not externally described, do I need to describe it internally (in the RPG program)?
PS. since this compiler message is just a level 10 warning, I don't have to change anything for it to compile. I'm just curious about possible solutions.