"Unexpected token" in a DB2 SQL statement that runs OK in Postgres I trying execute statement like following (i obfuscated it a little) in DB2:

UPDATE FIRSTTABLE SET fstatus=1 WHERE fid in (SELECT T.fid
  FROM FIRSTTABLE T
  INNER JOIN SECONDTABLE V ON V.efvid = T.efvid
  INNER JOIN OTHERTABLE E ON E.efid = V.efid
WHERE (efname = 'event')  AND  (eftname = 'eventhtml') FOR READ ONLY)


And receiving error:

42601][-104] An unexpected token "UPDATE FIRSTTABLE SET fstatus" was found following "BEGIN-OF-STATEMENT".  Expected tokens may include:  "&lt;query_into_expr_top&gt;".. SQLCODE=-104, SQLSTATE=42601, DRIVER=4.7.85


But, with, for example, postgresql this script works fine.
P.S. I am using DB2 Express, if it matters.
The problem is in the FOR READ ONLY statement. DB2 implicitly add's the same effect for all nested query's, and FOR READ ONLY makes it ambiguous. However, i dunno why i getting so strange error message.