I have spent all afternoon struggling with a mad DB2 issue, trying to do a query on a federated table from within php using odbc_query. I'm paraphrasing a bit but where I had a query like "select name from blah.customer" I was getting an error that translated to
A federated insert, update, or delete operation, or a call to federated procedure with an SQL data access indication of MODIFIES SQL DATA is invalid in a function, a data-change-table-reference, a dynamic compound statement, a trigger, and an application execution environment where a
* SAVEPOINT is in effect * scrollable cursor is used * target view contains multiple tables or nicknames
saying "whoah, you can't update that table"... I'm not trying to update it, really I just want to query it. Found another query that was running against another federated table and all was good, the main difference being it was a more complex query joining two tables... so I made my query more complex, joining in a table that I don't need, and it let my query through. Messed up. I think php's odbc_query was adding "for update" to the end of my query for some reason and I couldn't stop it (or even see it, to be sure) but by complexifying my query it stopped doing that.
The boy has had his hair cut today, he looks WELL CUTE