Google Cloud Sql Admin V1 Client - Class Database (1.6.0) Stay organized with collections Save and categorize content based on your preferences.
Reference documentation and code samples for the Google Cloud Sql Admin V1 Client class Database.
Represents a SQL database on the Cloud SQL instance.
Generated from protobuf messagegoogle.cloud.sql.v1.Database
Namespace
Google \ Cloud \ Sql \ V1Methods
__construct
Constructor.
| Parameters | |
|---|---|
| Name | Description |
data | arrayOptional. Data for populating the Message object. |
↳ kind | stringThis is always |
↳ charset | stringThe Cloud SQL charset value. |
↳ collation | stringThe Cloud SQL collation value. |
↳ etag | stringThis field is deprecated and will be removed from a future version of the API. |
↳ name | stringThe name of the database in the Cloud SQL instance. This does not include the project ID or instance name. |
↳ instance | stringThe name of the Cloud SQL instance. This does not include the project ID. |
↳ self_link | stringThe URI of this resource. |
↳ project | stringThe project ID of the project containing the Cloud SQL database. The Google apps domain is prefixed if applicable. |
↳ sqlserver_database_details | SqlServerDatabaseDetails |
getKind
This is alwayssql#database.
| Returns | |
|---|---|
| Type | Description |
string | |
setKind
This is alwayssql#database.
| Parameter | |
|---|---|
| Name | Description |
var | string |
| Returns | |
|---|---|
| Type | Description |
$this | |
getCharset
The Cloud SQL charset value.
| Returns | |
|---|---|
| Type | Description |
string | |
setCharset
The Cloud SQL charset value.
| Parameter | |
|---|---|
| Name | Description |
var | string |
| Returns | |
|---|---|
| Type | Description |
$this | |
getCollation
The Cloud SQL collation value.
| Returns | |
|---|---|
| Type | Description |
string | |
setCollation
The Cloud SQL collation value.
| Parameter | |
|---|---|
| Name | Description |
var | string |
| Returns | |
|---|---|
| Type | Description |
$this | |
getEtag
This field is deprecated and will be removed from a future version of theAPI.
| Returns | |
|---|---|
| Type | Description |
string | |
setEtag
This field is deprecated and will be removed from a future version of theAPI.
| Parameter | |
|---|---|
| Name | Description |
var | string |
| Returns | |
|---|---|
| Type | Description |
$this | |
getName
The name of the database in the Cloud SQL instance. This does not includethe project ID or instance name.
| Returns | |
|---|---|
| Type | Description |
string | |
setName
The name of the database in the Cloud SQL instance. This does not includethe project ID or instance name.
| Parameter | |
|---|---|
| Name | Description |
var | string |
| Returns | |
|---|---|
| Type | Description |
$this | |
getInstance
The name of the Cloud SQL instance. This does not include the project ID.
| Returns | |
|---|---|
| Type | Description |
string | |
setInstance
The name of the Cloud SQL instance. This does not include the project ID.
| Parameter | |
|---|---|
| Name | Description |
var | string |
| Returns | |
|---|---|
| Type | Description |
$this | |
getSelfLink
The URI of this resource.
| Returns | |
|---|---|
| Type | Description |
string | |
setSelfLink
The URI of this resource.
| Parameter | |
|---|---|
| Name | Description |
var | string |
| Returns | |
|---|---|
| Type | Description |
$this | |
getProject
The project ID of the project containing the Cloud SQL database. The Googleapps domain is prefixed if applicable.
| Returns | |
|---|---|
| Type | Description |
string | |
setProject
The project ID of the project containing the Cloud SQL database. The Googleapps domain is prefixed if applicable.
| Parameter | |
|---|---|
| Name | Description |
var | string |
| Returns | |
|---|---|
| Type | Description |
$this | |
getSqlserverDatabaseDetails
Generated from protobuf field.google.cloud.sql.v1.SqlServerDatabaseDetails sqlserver_database_details = 9;
| Returns | |
|---|---|
| Type | Description |
SqlServerDatabaseDetails|null | |
hasSqlserverDatabaseDetails
setSqlserverDatabaseDetails
Generated from protobuf field.google.cloud.sql.v1.SqlServerDatabaseDetails sqlserver_database_details = 9;
| Parameter | |
|---|---|
| Name | Description |
var | SqlServerDatabaseDetails |
| Returns | |
|---|---|
| Type | Description |
$this | |
getDatabaseDetails
| Returns | |
|---|---|
| Type | Description |
string | |
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2026-01-09 UTC.