1.0.0-alpha19 (latest) 1.0.0-alpha18

    public sealed class ExecuteSqlRequest : IMessage<ExecuteSqlRequest>, IEquatable<ExecuteSqlRequest>, IDeepCloneable<ExecuteSqlRequest>, IBufferMessage, IMessage

Reference documentation and code samples for the AlloyDB v1alpha API class ExecuteSqlRequest.

Request for ExecuteSql rpc.

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> ExecuteSqlRequest

## Implements

[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[ExecuteSqlRequest](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha.ExecuteSqlRequest), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[ExecuteSqlRequest](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha.ExecuteSqlRequest), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[ExecuteSqlRequest](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha.ExecuteSqlRequest), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html)

## Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Namespace

[Google.Cloud.AlloyDb.V1Alpha](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha)

## Assembly

Google.Cloud.AlloyDb.V1Alpha.dll

## Constructors

### ExecuteSqlRequest()

    public ExecuteSqlRequest()

### ExecuteSqlRequest(ExecuteSqlRequest)

    public ExecuteSqlRequest(ExecuteSqlRequest other)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `other` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha.ExecuteSqlRequest` |

## Properties

### Database

    public string Database { get; set; }

Required. Name of the database where the query will be executed.
Note - Value provided should be the same as expected from `SELECT
current_database();` and NOT as a resource reference.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### HasPassword

    public bool HasPassword { get; }

Gets whether the "password" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### Instance

    public string Instance { get; set; }

Required. The instance where the SQL will be executed. For the required
format, see the comment on the Instance.name field.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### InstanceAsInstanceName

    public InstanceName InstanceAsInstanceName { get; set; }

[InstanceName](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha.InstanceName)-typed view over the [Instance](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha.ExecuteSqlRequest#Google_Cloud_AlloyDb_V1Alpha_ExecuteSqlRequest_Instance) resource name property.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha.InstanceName` |   |

### Password

    public string Password { get; set; }

Optional. The database native user's password.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### SqlStatement

    public string SqlStatement { get; set; }

Required. SQL statement to execute on database. Any valid statement is
permitted, including DDL, DML, DQL statements.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### User

    public string User { get; set; }

Required. Database user to be used for executing the SQL.
Note - Value provided should be the same as expected from
`SELECT current_user;` and NOT as a resource reference.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### UserCredentialCase

    public ExecuteSqlRequest.UserCredentialOneofCase UserCredentialCase { get; }

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha.ExecuteSqlRequesthttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.AlloyDb.V1Alpha/latest/Google.Cloud.AlloyDb.V1Alpha.ExecuteSqlRequest.UserCredentialOneofCase` |   |

### ValidateOnly

    public bool ValidateOnly { get; set; }

Optional. If set, validates the sql statement by performing
syntax and semantic validation and doesn't execute the query.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |