Represents a MySQL database inside the Cloud SQL instance, hosted in Google's cloud. You can use the database resource to manage (insert, list, update, and delete) databases without having to connect to a Cloud SQL instance with a tool like MySQL client. When you manage MySQL databases with the Databases resource, you access the Cloud SQL instance, which may result in extra charges depending on the activation policy and billing plan selected for the instance. For more information, see the FAQ How is use of my instance calculated?
For a list of methods for this resource, see the end of this page.
Resource representations
A Database resource.
{
"kind": "sql#database",
"selfLink": string,
"name": string,
"etag": etag,
"project": string,
"instance": string,
"charset": string,
"collation": string
}
| Property name | Value | Description | Notes |
|---|---|---|---|
charset |
string |
The MySQL charset value. | writable |
collation |
string |
The MySQL collation value. | writable |
etag |
etag |
HTTP 1.1 Entity tag for the resource. | |
instance |
string |
The name of the Cloud SQL instance. This does not include the project ID. | |
kind |
string |
This is always sql#database. |
|
name |
string |
The name of the database in the Cloud SQL instance. This does not include the project ID or instance name. | |
project |
string |
The project ID of the project containing the Cloud SQL database. The Google apps domain is prefixed if applicable. | |
selfLink |
string |
The URI of this resource. |
Methods
- delete
- Deletes a resource containing information about a database inside a Cloud SQL instance.
- get
- Retrieves a resource containing information about a database inside a Cloud SQL instance.
- insert
- Creates a new database inside a Cloud SQL instance.
- list
- Lists databases in the specified Cloud SQL instance.
- patch
- Updates a resource containing information about a database inside a Cloud SQL instance. This method supports patch semantics.
- update
- Updates a database inside a Cloud SQL instance.