0 - 2 of 2 tags for 3707 error

Hello
Using version 15, I am stuck with 3707 error:
[5526] SPL1027:E(L417), Missing/Invalid SQL statement'E(3707):Syntax error, expected something like an 'END' keyword between ';' and the 'with' keyword.'.
Line 417 is the termination semicolon for a recursive query trying to concatenate a field:

SPL1027:E(L155), Missing/Invalid SQL statement'E(3707):Syntax error, expected something like ';' between a string or a Unicode character literal and '|'.'.
SPL1030:E(L156), Referring to undefined cursor 'stmt1'.