Skip to main content

databases_ddl

Overview

Namedatabases_ddl
TypeResource
Idgoogle.spanner.databases_ddl

Fields

NameDatatypeDescription
protoDescriptorsstringProto descriptors stored in the database. Contains a protobuf-serialized google.protobuf.FileDescriptorSet. For more details, see protobuffer self description.
statementsarrayA list of formatted DDL statements defining the schema of the database specified in the request.

Methods

NameAccessible byRequired ParamsDescription
projects_instances_databases_get_ddlSELECTdatabasesId, instancesId, projectsIdReturns the schema of a Cloud Spanner database as a list of formatted DDL statements. This method does not show pending schema updates, those may be queried using the Operations API.
projects_instances_databases_update_ddlEXECdatabasesId, instancesId, projectsIdUpdates the schema of a Cloud Spanner database by creating/altering/dropping tables, columns, indexes, etc. The returned long-running operation will have a name of the format /operations/ and can be used to track execution of the schema change(s). The metadata field type is UpdateDatabaseDdlMetadata. The operation has no response.