Interface MutationOrBuilder (6.68.0)

public interface MutationOrBuilder extends MessageOrBuilder

Implements

MessageOrBuilder

Methods

getDelete()

public abstract Mutation.Delete getDelete()

Delete rows from a table. Succeeds whether or not the named rows were present.

.google.spanner.v1.Mutation.Delete delete = 5;

Returns
Type Description
Mutation.Delete

The delete.

getDeleteOrBuilder()

public abstract Mutation.DeleteOrBuilder getDeleteOrBuilder()

Delete rows from a table. Succeeds whether or not the named rows were present.

.google.spanner.v1.Mutation.Delete delete = 5;

Returns
Type Description
Mutation.DeleteOrBuilder

getInsert()

public abstract Mutation.Write getInsert()

Insert new rows in a table. If any of the rows already exist, the write or transaction fails with error ALREADY_EXISTS.

.google.spanner.v1.Mutation.Write insert = 1;

Returns
Type Description
Mutation.Write

The insert.

getInsertOrBuilder()

public abstract Mutation.WriteOrBuilder getInsertOrBuilder()

Insert new rows in a table. If any of the rows already exist, the write or transaction fails with error ALREADY_EXISTS.

.google.spanner.v1.Mutation.Write insert = 1;

Returns
Type Description
Mutation.WriteOrBuilder

getInsertOrUpdate()

public abstract Mutation.Write getInsertOrUpdate()

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 insert_or_update, 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.

.google.spanner.v1.Mutation.Write insert_or_update = 3;

Returns
Type Description
Mutation.Write

The insertOrUpdate.

getInsertOrUpdateOrBuilder()

public abstract Mutation.WriteOrBuilder getInsertOrUpdateOrBuilder()

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 insert_or_update, 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.

.google.spanner.v1.Mutation.Write insert_or_update = 3;

Returns
Type Description
Mutation.WriteOrBuilder

getOperationCase()

public abstract Mutation.OperationCase getOperationCase()
Returns
Type Description
Mutation.OperationCase

getReplace()

public abstract Mutation.Write getReplace()

Like insert, except that if the row already exists, it is deleted, and the column values provided are inserted instead. Unlike insert_or_update, 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.

.google.spanner.v1.Mutation.Write replace = 4;

Returns
Type Description
Mutation.Write

The replace.

getReplaceOrBuilder()

public abstract Mutation.WriteOrBuilder getReplaceOrBuilder()

Like insert, except that if the row already exists, it is deleted, and the column values provided are inserted instead. Unlike insert_or_update, 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.

.google.spanner.v1.Mutation.Write replace = 4;

Returns
Type Description
Mutation.WriteOrBuilder

getUpdate()

public abstract Mutation.Write getUpdate()

Update existing rows in a table. If any of the rows does not already exist, the transaction fails with error NOT_FOUND.

.google.spanner.v1.Mutation.Write update = 2;

Returns
Type Description
Mutation.Write

The update.

getUpdateOrBuilder()

public abstract Mutation.WriteOrBuilder getUpdateOrBuilder()

Update existing rows in a table. If any of the rows does not already exist, the transaction fails with error NOT_FOUND.

.google.spanner.v1.Mutation.Write update = 2;

Returns
Type Description
Mutation.WriteOrBuilder

hasDelete()

public abstract boolean hasDelete()

Delete rows from a table. Succeeds whether or not the named rows were present.

.google.spanner.v1.Mutation.Delete delete = 5;

Returns
Type Description
boolean

Whether the delete field is set.

hasInsert()

public abstract boolean hasInsert()

Insert new rows in a table. If any of the rows already exist, the write or transaction fails with error ALREADY_EXISTS.

.google.spanner.v1.Mutation.Write insert = 1;

Returns
Type Description
boolean

Whether the insert field is set.

hasInsertOrUpdate()

public abstract boolean hasInsertOrUpdate()

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 insert_or_update, 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.

.google.spanner.v1.Mutation.Write insert_or_update = 3;

Returns
Type Description
boolean

Whether the insertOrUpdate field is set.

hasReplace()

public abstract boolean hasReplace()

Like insert, except that if the row already exists, it is deleted, and the column values provided are inserted instead. Unlike insert_or_update, 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.

.google.spanner.v1.Mutation.Write replace = 4;

Returns
Type Description
boolean

Whether the replace field is set.

hasUpdate()

public abstract boolean hasUpdate()

Update existing rows in a table. If any of the rows does not already exist, the transaction fails with error NOT_FOUND.

.google.spanner.v1.Mutation.Write update = 2;

Returns
Type Description
boolean

Whether the update field is set.