-3007: Invalid sequence for DML and DDL statements
Explanation:
Modifications were made to the catalog in the time between a <QUERY statement> which does not generate a result table and the corresponding <FETCH statement>s. These modifications concerned the underlying table of the <QUERY statement>.
User Action:
Repeat the QUERY and FETCH statement.