Actions71
- Asset Actions
- Attribute Actions
- Block Actions
- Database Actions
- Document Actions
- Markdown Table Actions
- Notebook Actions
- Search Actions
- System Actions
- Tag Actions
Database → Update Row
AI-generatedSummary
Update multiple cell values in an existing row of a SiYuan database identified by its AttributeView ID (AV ID) and row ID.
Inputs
- AV ID (required) — The AttributeView ID of the database block to update (this is the data-av-ID attribute, not the block ID). Use the List operation to find existing AV IDs.
- Row ID (required) — The unique identifier of the row to update within the database.
- Fields Mode — Defines how to specify the columns and values to update. Options are: byNameAndValue (column name and string value pairs), byColumnName (JSON object mapping column names to values), or byKeyId (column key IDs and corresponding values).
- Fields — Depending on the chosen Fields Mode, provide the column-value pairs to set in the row. Values are coerced as needed based on the column type.
Output shape
a single object summarizing the update result
The output includes the AV ID, row ID, and the count of fields that were set as part of the update operation.
Examples
Example 1: Update a database row by specifying column names and values
Provide the AV ID, row ID, set Fields Mode to 'By Column Name & Value (Collection)', and specify each field's column name and desired value in the Fields collection.