| Previous | Next |  | Contents | Index | Glossary

## Workflow Core APIs

PL/SQL procedures called by function activities can use a set of core Oracle Workflow APIs to raise and catch errors.

When a PL/SQL procedure called by a function activity either raises an unhandled exception, or returns a result beginning with 'ERROR:', the Workflow Engine sets the function activity's status to ERROR and sets the columns ERROR_NAME, ERROR_MESSAGE, and ERROR_STACK in the table WF_ITEM_ACTIVITY_STATUSES to reflect the error.

The columns ERROR_NAME and ERROR_MESSAGE get set to either the values returned by a call to WF_CORE.RAISE( ), or to the SQL error name and message if no call to RAISE( ) is found. The column ERROR_STACK gets set to the contents set by a call to WF_CORE.CONTEXT( ), regardless of the error source.

> Note: The columns ERROR_NAME, ERROR_MESSAGE, and ERROR_STACK are also defined as item type attributes for the System: Error predefined item type. You can reference from the error process that you associate with an activity, the information in these columns. See: Default Error Process.

The following APIs can be called by an application program or workflow function in the runtime phase to handle error processing. These APIs are stored in the PL/SQL package called WF_CORE.

- CLEAR

- GET_ERROR

- TOKEN

- RAISE

- CONTEXT

- TRANSLATE

### See Also

Standard API for an Oracle Workflow PL/SQL Stored Procedure

| Previous | Next |  | Contents | Index | Glossary