Entering content frame

This graphic is explained in the accompanying text Example for Using WHENEVER Statements Locate the document in its SAP Library structure

The following examples show the usage of different WHENEVER statements.

 

EXEC SQL WHENEVER SQLWARNING CALL warnproc();

EXEC SQL SELECT * FROM dual;

/* receives a warning and calls warnproc */

 

EXEC SQL WHENEVER SQLERROR CALL errproc();

EXEC SQL DELETE FROM unknowntable;

/* receives an error and calls errorproc */

 

EXEC SQL WHENEVER SQLERROR STOP;

/* receives also an error but stops execution */

EXEC SQL DELETE FROM unknowntable;

 

Leaving content frame