logo  
Google
 

DB2 SQL-Error: -751

SQLState: 38003

Short Description: SPECIFIC NAME ATTEMPTED TO EXECUTE AN SQL STATEMENT THAT IS NOT ALLOWED

A stored procedure or user-defined function attempted to execute an SQL statement that is not allowed. Stored procedure A stored procedure issued an SQL statement that forced the DB2 thread to roll back the unit of work. The SQL statement that caused the thread to be placed in the MUST_ROLLBACK state is one of the following: COMMIT ROLLBACKAll further SQL statements are rejected until the SQL application that issued the SQL CALL statement rolls back the unit of work. When control returns to the SQL application that issued the SQL CALL statement, the SQL application must roll back the unit of work. This can be done by issuing an SQL ROLLBACK statement or the equivalent IMS or CICS operation. User-defined function External function object-name issued one of the following SQL statements: v COMMIT v ROLLBACKSystem action: The statement cannot be executed. Programmer response: Remove the unsupported statement from your stored procedure or user-defined function. Remotely called stored procedures cannot execute embedded SQL Commit and/or Rollback statements unless: v The connection with the requester system uses one phase commit protocols v The requester system indicates that commits are allowed (via sending a DRDA RDBCMTOK=TRUE indication) when the stored procedure is called. Attention: For DB2 Connect requester systems, this requires that the client application must use Connect Type 1, or Remote Unit of Work connections. Connect Type 2 or Distributed Unit of Work connections will cause DB2 Connect to indicate that commits are not allowed, thus embedded SQL Commit and/or Rollback statements in a stored procedure will fail.Any Commit or Rollback statements in the stored procedure must be removed, or the client application should be modified to establish an environment that allows the stored procedure to execute SQL Commit and/or Rollback statements.

 <-  BACK TO INDEX