|
Posted by Serge Rielau on 03/19/06 16:49
Bob Stearns wrote:
> I am trying to write a small app in php to make the 'COMMENT' statement
> a bit more friendly, so we might do more documentation. My problem is a
> set of error statements which have nothing to do with what I'm doing.
> For instance when I try to run the trigger list with the code below, I
> get the error message:
>
> 42832--[IBM][CLI Driver][DB2/LINUX] SQL0607N "UPDATE" is not defined for
> system objects. SQLSTATE=42832
>
> $sql = "SELECT trigname AS obj_name
> FROM syscat.triggers
> WHERE trigschema='$db_schema'
> ";
> dosql($sql, "S OBJ", -1, "", $res, $n);
>
> I get different, but similar, error messages when I try tables and views:
>
> 42808--[IBM][CLI Driver][DB2/LINUX] SQL0151N The column
> "MAXFREESPACESEARCH" cannot be updated. SQLSTATE=42808
>
> 42808--[IBM][CLI Driver][DB2/LINUX] SQL0151N The column "SEQNO" cannot
> be updated. SQLSTATE=42808
>
> When I run the statements in my frontend, ADS, they all do just what I
> expect. Since I don't know where the problem lies, I posted this
> question to two newsgroups.
Appears your client attached a FOR UPDATE clause.
Try this:
SELECT trigname AS obj_name
FROM syscat.triggers
WHERE trigschema='$db_schema'
FOR READ ONLY
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab
[Back to original message]
|