# UPDATE STORE

## Syntax <a href="#synopsis" id="synopsis"></a>

```sql
UPDATE STORE
    store_name
WITH (store_parameter = value [, ...]);
```

## Description <a href="#description" id="description"></a>

Updates a [store](/overview/core-concepts/store.md) with new store parameters.

### Arguments

#### store\_name

Name of the store to update. If the name is case-sensitive, you must wrap it in double quotes; otherwise, the system uses the lower case name.

#### WITH (store\_parameter = value \[, …​ ])

This clause specifies store parameters; see [store parameters](#store_parameters) below for more information.

### Store Parameters <a href="#store_parameters" id="store_parameters"></a>

| Parameter Name               | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| ---------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `type`                       | <p>Specifies the store type.</p><p><strong>Required:</strong> No</p><p><strong>Type:</strong> <code>STORE\_TYPE</code></p><p><strong>Valid values:</strong> <code>KAFKA</code>, <code>KINESIS</code>, <code>POSTGRESQL</code>, or <code>ORACLE</code>.</p>                                                                                                                                                                                                                      |
| `uris`                       | <p>List of comma-separated <code>host:port</code> URIs to connect to the store.</p><p><br><strong>Required:</strong> No<br><strong>Type:</strong> String</p>                                                                                                                                                                                                                                                                                                                    |
| `tls.disabled`               | <p>Specifies if the store should be accessed over TLS.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> <code>FALSE</code></p><p><strong>Type:</strong> Boolean</p><p><strong>Valid values:</strong> <code>TRUE</code> or <code>FALSE</code></p>                                                                                                                                                                                                         |
| `tls.verify_server_hostname` | <p>Specifies if the server CNAME should be validated against the certificate.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> <code>TRUE</code><br><strong>Type:</strong> Boolean<br><strong>Valid values:</strong> <code>TRUE</code> or <code>FALSE</code></p>                                                                                                                                                                                         |
| `tls.ca_cert_file`           | <p>Path to a CA certificate file in PEM format.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> Public CA chains.<br><strong>Type:</strong> String</p>                                                                                                                                                                                                                                                                                                  |
| `tls.cipher_suites`          | <p>Comma-separated list of cipher suites to use when establishing a TLS connection.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> \[]<br><strong>Type:</strong> List</p>                                                                                                                                                                                                                                                                              |
| `tls.protocols`              | <p>Comma-separated list TLS protocol versions to use while establishing a TLS connection.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> <code>TLSv1.2,TLSv1.1,TLSv1</code><br><strong>Type:</strong> List<br><strong>Valid values:</strong> TLS protocols with version</p>                                                                                                                                                                            |
| `schema_registry.name`       | <p>Name of a schema registry to associate with the store. A schema registry must first be created using the <a href="/pages/oh4MNfxwa0ePTYSjYZnr">CREATE SCHEMA\_REGISTRY</a> DDL statement. Only one schema registry can be associated with a store.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> None<br><strong>Type:</strong> String<br><strong>Valid values:</strong> See <a href="/pages/mMcG9CIn7Cxw99Z4uvuC">LIST SCHEMA\_REGISTRIES</a></p> |
| `properties.file`            | <p>The file path to a .yaml file containing other store parameters.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> None<br><strong>Type:</strong> String<br><strong>Valid values:</strong> File path in current user's filesystem</p>                                                                                                                                                                                                                  |

### **ClickHouse-Specific Parameters**

Parameters to be used if `type` is `CLICKHOUSE`:

| Parameter Name        | Description                                                                                                                                                                                                                |
| --------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `clickhouse.username` | <p>Username to connect to the database instance specified with the store's <code>uris</code> parameter.<br><br><strong>Required:</strong> Yes<br><strong>Default value:</strong> None<br><strong>Type:</strong> String</p> |
| `clickhouse.password` | <p>Password to connect to the database instance using the store's <code>username</code> parameter.<br><br><strong>Required:</strong> Yes</p><p><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>   |

### Databricks-Specific Parameters

Parameters to be used if `type` is `DATABRICKS`:

| Parameter Name          | Description                                                                                                                                                                                                 |
| ----------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `databricks.app_token`  | <p>Databricks personal access token used when authenticating with a Databricks workspace.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> None<br><strong>Type:</strong> String</p> |
| `aws.access_key_id`     | <p>AWS access key ID used for writing data to S3.<br><br><strong>Required:</strong> Yes</p><p><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                     |
| `aws.secret_access_key` | <p>AWS secret access key used for writing data to S3.</p><p><br><strong>Required:</strong> Yes<br><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                 |

### Iceberg AWS Glue Catalog-Specific Parameters

| ParameterName                    | Description                                                                                                                                                                                                                                                                                                        |
| -------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `aws.iam_role_arn`               | <p>AWS IAM role ARN to use when authenticating with S3<br><br><strong>Required:</strong> No. If updating <code>aws.access\_key\_id</code> or <code>aws.secret\_access\_key</code>, both must be specified.<br><strong>Default value:</strong> <code>NONE</code><br><strong>Type:</strong> <code>STRING</code></p>  |
| `aws.iam_external_id`            | <p>IAM External ID<br><br><strong>Required:</strong> No. If updating <code>aws.access\_key\_id</code> or <code>aws.secret\_access\_key</code>, both must be specified.<br><strong>Default value:</strong> <code>NONE</code><br><strong>Type:</strong> <code>STRING</code></p>                                      |
| `aws.access_key_id`              | <p>AWS IAM role ARN to use when authenticating with S3.<br><br><strong>Required:</strong> No. If updating <code>aws.access\_key\_id</code> or <code>aws.secret\_access\_key</code>, both must be specified.<br><strong>Default value:</strong> <code>NONE</code><br><strong>Type:</strong> <code>STRING</code></p> |
| `aws.secret_access_key`          | <p>IAM External ID<br><br><strong>Required:</strong> No. If updating <code>aws.access\_key\_id</code> or <code>aws.secret\_access\_key</code>, both must be specified.<br><strong>Default value:</strong> <code>NONE</code><br><strong>Type:</strong> <code>STRING</code></p>                                      |
| `aws.region`                     | <p>AWS region in which the glue catalog resides.<br><br><strong>Required:</strong> No</p><p><strong>Default value:</strong> <code>NONE</code><br><strong>Type:</strong> <code>STRING</code></p>                                                                                                                    |
| `iceberg.warehouse.default_path` | <p>Iceberg default warehouse path.<br><br><strong>Required:</strong> No</p><p><strong>Default value:</strong> <code>NONE</code><br><strong>Type:</strong> <code>STRING</code></p>                                                                                                                                  |
| `iceberg.catalog.id`             | <p>Iceberg catalog ID<br><br><strong>Required:</strong> No</p><p><strong>Default value:</strong> <code>NONE</code><br><strong>Type:</strong> <code>STRING</code></p>                                                                                                                                               |

### **Kafka-Specific Parameters**

Parameters to be used if `type` is `KAFKA`:

| Parameter Name             | Description                                                                                                                                                                                                                                                                                                                                            |
| -------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `kafka.sasl.hash_function` | <p>SASL hash function to use when authenticating with Apache Kafka brokers.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> <code>NONE</code>.<br><strong>Type:</strong> <code>HASH\_FUNCTION</code><br><strong>Valid values:</strong> <code>NONE</code>, <code>PLAIN</code>, <code>SHA256</code>, and <code>SHA512</code></p> |
| `kafka.sasl.username`      | <p>Username to use when authenticating with Apache Kafka brokers.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                                                                                                                                                    |
| `kafka.sasl.password`      | <p>Password to use when authenticating with Apache Kafka brokers.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                                                                                                                                                    |
| `kafka.msk.aws_region`     | <p>AWS region to use when authenticating with MSK.</p><p><strong>Required:</strong> Yes, if <code>kafka.sasl.hash\_function</code> is <code>AWS\_MSK\_IAM</code><br><strong>Default value:</strong> None<br><strong>Type:</strong> String<br><strong>Example:</strong> <code>us-east-1</code></p>                                                      |
| `kafka.msk.iam_role_arn`   | <p>AWS IAM role ARN to use when authenticating with MSK.</p><p><strong>Required:</strong> Yes, if <code>kafka.sasl.hash\_function</code> is <code>AWS\_MSK\_IAM</code><br><strong>Default value:</strong> None<br><strong>Type:</strong> String<br><strong>Example:</strong> <code>arn:aws:iam::123456789012:role/example-IAM-role</code></p>          |
| `tls.client.cert_file`     | <p>Path to a client certificate file in PEM format.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                                                                                                                                                                  |
| `tls.client.key_file`      | <p>Path to the client key file in PEM format.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                                                                                                                                                                        |

### **Kinesis-Specific Parameters**

Parameters to be used if `type` is `KINESIS`:

| Parameter Name              | Description                                                                                                                                                                                                                                                                                                                                                                     |
| --------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `kinesis.iam_role_arn`      | <p>AWS IAM role ARN to use when authenticating with an Amazon Kinesis service.</p><p><strong>Required:</strong> Yes, unless authenticating with the Amazon Kinesis Service using static AWS credentials.<br><strong>Default value:</strong> None<br><strong>Type:</strong> String<br><strong>Example:</strong> <code>arn:aws:iam::123456789012:role/example-IAM-role</code></p> |
| `kinesis.access_key_id`     | <p>AWS IAM access key to use when authenticating with an Amazon Kinesis service.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                                                                                                                                                              |
| `kinesis.secret_access_key` | <p>AWS IAM secret access key to use when authenticating with an Amazon Kinesis service.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                                                                                                                                                       |

### S3-Specific Parameters

Parameters to be used if `type` is `S3`:

| Parameter Name          | Description                                                                                                                                                                                                                                                                                 |
| ----------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `aws.iam_role_arn`      | <p>AWS IAM role ARN to use when authenticating with S3.<br><br><strong>Required:</strong> No. If updating <code>aws.access\_key\_id</code> or <code>aws.secret\_access\_key</code>, both must be specified.</p><p><strong>Default value:</strong> None<br><strong>Type:</strong> String</p> |
| `aws.iam_external_id`   | <p>IAM External ID.<br><br><strong>Required:</strong> Yes, if <code>aws.iam\_role\_arn</code> is specified.</p><p><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                                                                                 |
| `aws.access_key_id`     | <p>AWS IAM role ARN to use when authenticating with S3.<br><br><strong>Required:</strong> No. If updating <code>aws.access\_key\_id</code> or <code>aws.secret\_access\_key</code>, both must be specified.</p><p><strong>Default value:</strong> None<br><strong>Type:</strong> String</p> |
| `aws.secret_access_key` | <p>IAM External ID.<br><br><strong>Required:</strong> No. If updating <code>aws.access\_key\_id</code> or <code>aws.secret\_access\_key</code>, both must be specified.</p><p><strong>Default value:</strong> None<br><strong>Type:</strong> String</p>                                     |

### Oracle-Specific Parameters

Parameters to be used if `type` is `ORACLE`:

| Parameter Name        | Description                                                                                                                                                                                                                         |
| --------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `oracle.username`     | <p>Username to connect to the Oracle instance specified with the store's <code>uris</code> parameter.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> Existing value<br><strong>Type:</strong> String</p>   |
| `oracle.password`     | <p>Password to connect to the Oracle instance using the store's <code>oracle.username</code> parameter.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> Existing value<br><strong>Type:</strong> String</p> |
| `oracle.service_name` | <p>Oracle service name for the target database.<br><br><strong>Required:</strong> No<br><strong>Default value:</strong> Existing value<br><strong>Type:</strong> String</p>                                                         |

{% hint style="info" %}
When rotating Oracle credentials, specify `oracle.username` and `oracle.password` together in the same `UPDATE STORE` statement.
{% endhint %}

### Snowflake-Specific Parameters

Snowflake stores don't support this command.

## Examples

#### Attach a schema registry to a store

The following example updates the store named "demostore" to attach a schema registry named "ConfluentCloudSR".

```sh
demodb.public/demostore# UPDATE STORE
    demostore
WITH (
    'schema_registry.name' = "ConfluentCloudSR"
);
+------------+------------+------------+------------------------------------------+
|  Type      |  Name      |  Command   |  Summary                                 |
+============+============+============+==========================================+
| store      | demostore  | UPDATE     | store "demostore" was successfully       |
|            |            |            | updated                                  |
+------------+------------+------------+------------------------------------------+
```

#### Update Oracle service name

The following example updates the Oracle service name for store `oracle_store`.

```sql
UPDATE STORE
    oracle_store
WITH (
    'oracle.service_name' = 'FREEPDB2'
);
```

#### Rotate Oracle username and password

The following example updates the Oracle credentials for store `oracle_store`.

```sql
UPDATE STORE
    oracle_store
WITH (
    'oracle.username' = 'app_user_v2',
    'oracle.password' = 'new_password'
);
```

#### Update Oracle service name and credentials together

The following example updates the service name and rotates credentials in one statement.

```sql
UPDATE STORE
    oracle_store
WITH (
    'oracle.service_name' = 'FREEPDB2',
    'oracle.username' = 'app_user_v2',
    'oracle.password' = 'new_password'
);
```

#### Disable TLS for an Oracle store

The following example disables TLS for store `oracle_store`.

```sql
UPDATE STORE
    oracle_store
WITH (
    'tls.disabled' = TRUE
);
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.deltastream.io/reference/sql-syntax/ddl/update-store.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
