In addition to the Data Manipulation Language (DML) based APIs, Cloud Spanner supports the mutation API, where the application describes data modification using a data structure instead of a SQL statement.
This class serves as a wrapper for all mutations types. Use the builders, such as InsertMutationBuilder or UpdateMutationBuilder to create objects of this class.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-07-09 UTC."],[[["This webpage provides documentation for the `Mutation` class within the Google Cloud Spanner C++ library, with version 2.24.0 being the currently displayed version and 2.37.0-rc being the latest."],["The `Mutation` class is a wrapper for Cloud Spanner mutations, allowing for data modifications using a data structure instead of SQL statements."],["The Mutation API offers different constructors, including an empty constructor and copy constructors."],["The `Mutation` class provides operators, such as assignment operators, for effective manipulation."],["The `as_proto()` functions in the `Mutation` class convert the mutation to the underlying protocol buffer representation."]]],[]]