class Databases extends Resource (View source)

The "databases" collection of methods.

Typical usage is:

 $sqladminService = new Google\Service\SQLAdmin(...);
 $databases = $sqladminService->databases;

Methods

delete(string $project, string $instance, string $database, array $optParams = [])

Deletes a database from a Cloud SQL instance. (databases.delete)

get(string $project, string $instance, string $database, array $optParams = [])

Retrieves a resource containing information about a database inside a Cloud SQL instance. (databases.get)

insert(string $project, string $instance, Database $postBody, array $optParams = [])

Inserts a resource containing information about a database inside a Cloud SQL instance. Note: You can't modify the default character set and collation.

listDatabases(string $project, string $instance, array $optParams = [])

Lists databases in the specified Cloud SQL instance.

patch(string $project, string $instance, string $database, Database $postBody, array $optParams = [])

Partially updates a resource containing information about a database inside a Cloud SQL instance. This method supports patch semantics. (databases.patch)

update(string $project, string $instance, string $database, Database $postBody, array $optParams = [])

Updates a resource containing information about a database inside a Cloud SQL instance. (databases.update)

Details

Operation delete(string $project, string $instance, string $database, array $optParams = [])

Deletes a database from a Cloud SQL instance. (databases.delete)

Parameters

string $project

Project ID of the project that contains the instance.

string $instance

Database instance ID. This does not include the project ID.

string $database

Name of the database to be deleted in the instance.

array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

Database get(string $project, string $instance, string $database, array $optParams = [])

Retrieves a resource containing information about a database inside a Cloud SQL instance. (databases.get)

Parameters

string $project

Project ID of the project that contains the instance.

string $instance

Database instance ID. This does not include the project ID.

string $database

Name of the database in the instance.

array $optParams

Optional parameters.

Return Value

Database

Exceptions

Exception

Operation insert(string $project, string $instance, Database $postBody, array $optParams = [])

Inserts a resource containing information about a database inside a Cloud SQL instance. Note: You can't modify the default character set and collation.

(databases.insert)

Parameters

string $project

Project ID of the project that contains the instance.

string $instance

Database instance ID. This does not include the project ID.

Database $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

DatabasesListResponse listDatabases(string $project, string $instance, array $optParams = [])

Lists databases in the specified Cloud SQL instance.

(databases.listDatabases)

Parameters

string $project

Project ID of the project that contains the instance.

string $instance

Cloud SQL instance ID. This does not include the project ID.

array $optParams

Optional parameters.

Return Value

DatabasesListResponse

Exceptions

Exception

Operation patch(string $project, string $instance, string $database, Database $postBody, array $optParams = [])

Partially updates a resource containing information about a database inside a Cloud SQL instance. This method supports patch semantics. (databases.patch)

Parameters

string $project

Project ID of the project that contains the instance.

string $instance

Database instance ID. This does not include the project ID.

string $database

Name of the database to be updated in the instance.

Database $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

Operation update(string $project, string $instance, string $database, Database $postBody, array $optParams = [])

Updates a resource containing information about a database inside a Cloud SQL instance. (databases.update)

Parameters

string $project

Project ID of the project that contains the instance.

string $instance

Database instance ID. This does not include the project ID.

string $database

Name of the database to be updated in the instance.

Database $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception