Help Centre › Building Processes
This article describes the RPA Database functionality to rollback a database transaction.
For a full list of available functions, please read DATABASE functions.
Description
The Rollback transaction function rolls back the current database transaction, undoing all changes made since the transaction began. The connection returns to autocommit mode after the rollback.
Setting it up
To use the Rollback transaction function, follow these instructions:
{{popups:rpas/add:action=db-rollback}}
Once on a process map:
- Navigate to the process where you would like to add the Rollback transaction function
- Click on the green button's drop-down (right side of the green button labelled "Process")
- On the menu that appears, click on the "+ Activity" item
- From here you can select the Rollback transaction option
- Click "Add" once you are done
Input parameters
| Parameter | Required | Type | Default | Description |
|---|---|---|---|---|
| Name | Yes | Text | - | The alias of a previously opened connection (from db-connect) |
Output variables
This action does not produce output variables.
Errors
| Error | Description |
|---|---|
| Connection not found | No open connection exists with the specified name |
| No active transaction | There is no active transaction to rollback on this connection |
Tips
- Use Rollback in error handlers within try-catch blocks to undo changes when something goes wrong
- Always pair with Begin transaction