I'm finishing a PL/SQL block but the final update statement is giving me a headache.
The following EXECUTE INMEDIATE thows me an SQLCODE -932 and program breaks.
EXECUTE IMMEDIATE 'UPDATE RS2QTCIN cin SET cin.date_end = '|| dateINSERT ||' WHERE cin.id = '|| REG1.c1id;
The query is just simple, dateINSERT is a variable defined in the declaration block and the value at the end(REG1.c1id), is a result of a cursor also defined.
The update query seems correct and the variables are concatenated with the query string.