Progress
Embedded SQL-92
Guide and Reference
Interrupting the Execution of an SQL Statement
During the execution of an SQL statement an interrupt can occur. When this happens the statement being executed fails and the database returns an error code in the SQLCA. The database rolls back any changes made by this particular statement. The database returns to the state it held before execution of the SQL statement.
EXAMPLEIn this sequence of operations, if the interrupt occurs during the execution of the UPDATE statement, then the UPDATE statement returns an error and all the changes made by the UPDATE statement are undone. The changes made by the INSERT statement are retained. If the statement execution proceeds to the COMMIT statement, then only the INSERT operation is made permanent, as shown in the following example:
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |