swapDatabase
Last updated: January 27, 2026
Atomically swaps the contents of two databases in Snowflake. This operation exchanges all schemas, tables, and objects between the databases in a single transaction.
Note: Automatic rollback swaps the databases back.
Known limitation: This change type does not support database inspection features (snapshot, diff, diff-changelog, and generate-changelog commands).
Available attributes
Attribute | Type | Description | Required |
|---|---|---|---|
| String | Name of the first database to swap | Yes |
| String | Name of the second database to swap with | Yes |
| Boolean | Only execute if both databases exist | No |
loading
loading
loading
loading
More like this
Rename a database
Create a new database
Clone an existing database
Official Snowflake documentation