Save Record
Last updated
Last updated
This action will insert a new record or update specific fields of an existing record on a collection.
The action uses the following settings:
Setting | Description | |
Bot | The bot that is providing collection access. The current bot is selected by default. | |
Collection | The collection to be used for the action | |
Save Mode | Set whatever the save action should fully replace any data in the existing record or only update the specified fields | |
Record Unique Id | The unique id of the record to be deleted. If left empty, Filter Operations will be used instead. |
This action alone does not produce any result. At least one Field Operation must be attached for the action to be executed. Assuming we want to increase by 50 the cost of a product with a specific id, a complete Save Record action may look like the example below:
Regardless of the selected Save Mode, if no unique id is specified for the record or no record exist with the specified value, the Save Mode will be automatically set to replace whole record mode, possibly generating a new database record.
This action automatically triggers all of the Set Field operations attached.
This action produces the following variables after being triggered:
Variable | Description |
last_database_object_id | The unique id of the record that has been updated or inserted. |
Channel specific availability follows the table below:
Channel | Availability |
Fully Available. | |
Fully Available. | |
SMS | Fully Available. |
Telegram | Fully Available. |
Web | Fully Available. |
Alexa | Fully Available. |
Google Assistant | Fully Available. |
Slack | Fully Available. |
API | Fully Available. |
This action requires an active Database package.