The Update Tables Node writes data from a workflow into a Rayven Primary or Secondary Table. It supports flexible row-matching using keys and allows multiple fields to be updated in a single operation.
Step-by-Step: How to Configure the Update Tables Node
-
Add the node to your workflow
Drag the “Update Tables” node into your canvas from the node library. -
Set a Node Name
Give your node a clear name to describe its function (e.g.,UpdateDeviceStatus
). -
Choose a Table
Use the Select Table dropdown to choose the target Primary or Secondary table you want to update. -
Define the Row Match Key
-
Under “Write JSON key”, enter the key from your payload that holds the unique identifier (e.g.,
"deviceId"
). -
Under “To Column”, choose the column in the table to match against (e.g.,
"UID"
).
-
-
Map Payload Values to Columns
Add one or more row updates:-
For each, define:
-
Write JSON key: the key from the incoming payload (e.g.,
"status"
,"lastSeen"
). -
To Column: the corresponding column in the table to update (e.g.,
"DeviceStatus"
,"LastSeenAt"
).
-
-
-
Save and connect
Link the node to upstream logic and test using sample data or debug mode.
Basic Settings
Field | Description |
---|---|
Node Name* | A custom label to identify this node within your workflow. |
Table Selection
Field | Description |
---|---|
Select Table | The target Rayven table where the updates will be written. Supports both Primary and Secondary tables. |
Data Mapping
To update rows in the selected table, define mappings from incoming JSON keys to target table columns. Each mapping consists of a key (to identify the row) and values to be written.
Record Match (Key)
Field | Description |
---|---|
Write JSON Key* | The name of the key in the incoming payload that identifies the row to update. |
To Column* | The column in the table to match against (typically UID or another unique identifier). |
Field Update(s)
Field | Description |
---|---|
Write JSON Key* | The name of the key in the payload that holds the new value to write. |
To Column* | The destination column in the table that should receive the new value. |
➡ You can define multiple key-value column mappings per node (e.g., update several fields in one step).
Best Practices
-
Always use a unique and indexed column (like
UID
) for key matching to ensure performance. -
Make sure the incoming payload contains all required fields before attempting an update.
-
If no row matches the key, no update will occur unless the table allows inserts (check system behavior).
-
Use debug mode to trace which rows were updated, especially when handling dynamic or looped inputs.
Frequently Asked Questions (FAQ)
Q: What happens if multiple rows match the key condition?
A: Only the first matching row is updated. Always ensure your keys are unique to avoid unintended behavior.
Q: Can I update multiple rows at once?
A: Yes, if your workflow sends a batch payload (array), the node can loop through and apply updates per item.
Q: Does the node create new rows if no match is found?
A: No, the Update Tables Node only modifies existing rows. Use the Insert Tables Node for new entries.
Q: Can I update both Primary and Secondary tables?
A: Yes, but only one table per node. Use multiple nodes to write to different tables.