Show / Hide Table of Contents

Class ExecuteBatchDmlResponse

The response for ExecuteBatchDml. Contains a list of ResultSet messages, one for each DML statement that has successfully executed, in the same order as the statements in the request. If a statement fails, the status in the response body identifies the cause of the failure. To check for DML statements that failed, use the following approach: 1. Check the status in the response message. The google.rpc.Code enum value OK indicates that all statements were executed successfully. 2. If the status was not OK, check the number of result sets in the response. If the response contains N ResultSet messages, then statement N+1 in the request failed. Example 1: * Request: 5 DML statements, all executed successfully. * Response: 5 ResultSet messages, with the status OK. Example 2: * Request: 5 DML statements. The third statement has a syntax error. * Response: 2 ResultSet messages, and a syntax error (INVALID_ARGUMENT) status. The number of ResultSet messages indicates that the third statement failed, and the fourth and fifth statements were not executed.

Inheritance
object
ExecuteBatchDmlResponse
Implements
IDirectResponseSchema
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Google.Apis.Spanner.v1.Data
Assembly: Google.Apis.Spanner.v1.dll
Syntax
public class ExecuteBatchDmlResponse : IDirectResponseSchema

Properties

ETag

The ETag of the item.

Declaration
public virtual string ETag { get; set; }
Property Value
Type Description
string

PrecommitToken

Optional. A precommit token is included if the read-write transaction is on a multiplexed session. Pass the precommit token with the highest sequence number from this transaction attempt should be passed to the Commit request for this transaction.

Declaration
[JsonProperty("precommitToken")]
public virtual MultiplexedSessionPrecommitToken PrecommitToken { get; set; }
Property Value
Type Description
MultiplexedSessionPrecommitToken

ResultSets

One ResultSet for each statement in the request that ran successfully, in the same order as the statements in the request. Each ResultSet does not contain any rows. The ResultSetStats in each ResultSet contain the number of rows modified by the statement. Only the first ResultSet in the response contains valid ResultSetMetadata.

Declaration
[JsonProperty("resultSets")]
public virtual IList<ResultSet> ResultSets { get; set; }
Property Value
Type Description
IList<ResultSet>

Status

If all DML statements are executed successfully, the status is OK. Otherwise, the error status of the first failed statement.

Declaration
[JsonProperty("status")]
public virtual Status Status { get; set; }
Property Value
Type Description
Status

Implements

IDirectResponseSchema
In this article
Back to top Generated by DocFX