SQL-438 error or S04E abend.

Document ID : KB000023197
Last Modified Date : 14/02/2018
Show Technical Document Details


ALTER PROCEDURE DDL produced by RC/Update (via RCO) to ALTER a SQL Stored procedure from READS SQL DATA to MODIFIES SQL DATA or back will fail when the actual SQL body is not consistent with the new the READS/MODIFIES/CONTAINS attribute value. CREATE PROCEDURE DDL similarly fails when the READS/MODIFIES/CONTAINS attribute value is inconsistent with the SQL body. Symptoms/results include subsequent S04E abend and/or SQLCODE -438 for the PTLBDBC subtask.

RC/Update currently cannot validate the contents of the SQL Body against the requested ALTER or CREATE, so DDL can be produced that will fail with abend S04E or SQLCODE -438 when the procedure being altered contains SQL that is not consistent with the READS/MODIFIES/CONTAINS attribute status.

ALTER PROCEDURE <creator>.<name> READS SQL DATA;         


At the time of this writing, an IBM APAR is under development to replace the abend S04E and SQL-438 with SQLCODE -577 (ALTER PROCEDURE, CREATE PROCEDURE).

It is recommended that the IBM DB2 service APAR be applied when it becomes available and that caution be exercised when altering or creating a procedure to ensure consistency between the SQL Body and the READS/MODIFIES/CONTAINS attribute value.