A modification to one or more Cloud Spanner rows. Mutations can be applied to a Cloud Spanner database by sending them in a sessions.commit call.
JSON representation
{// Union field operation can be only one of the following:"insert": {object (Write)},"update": {object (Write)},"insertOrUpdate": {object (Write)},"replace": {object (Write)},"delete": {object (Delete)}// End of list of possible types for union field operation.}
Fields
Union field operation. Required. The operation to perform. operation can be only one of the following:
Like insert, except that if the row already exists, then its column values are overwritten with the ones provided. Any column values not explicitly written are preserved.
When using insertOrUpdate, just as when using insert, all NOT
NULL columns in the table must be given a value. This holds true even when the row already exists and will therefore actually be updated.
Like insert, except that if the row already exists, it is deleted, and the column values provided are inserted instead. Unlike insertOrUpdate, this means any values not explicitly written become NULL.
In an interleaved table, if you create the child table with the ON DELETE CASCADE annotation, then replacing a parent row also deletes the child rows. Otherwise, you must delete the child rows before you replace the parent row.
The values to be written. values can contain more than one list of values. If it does, then multiple rows are written, one for each entry in values. Each list in values must have exactly as many entries as there are entries in columns above. Sending multiple lists is equivalent to sending multiple Mutations, each containing one values entry and repeating table and columns. Individual values in each list are encoded as described here.
Required. The primary keys of the rows within table to delete. The primary keys must be specified in the order in which they appear in the PRIMARY KEY() clause of the table's equivalent DDL statement (the DDL statement used to create the table). Delete is idempotent. The transaction will succeed even if some or all rows do not exist.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-10-09 UTC."],[],[]]