createDatabaseFromShare
Creates a database from a share provided by another Snowflake account. This is a consumer-side operation that creates a read-only database pointing to shared data.
Note: Automatic rollback drops the database.
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 database to create | Yes |
| String | Account identifier of the data provider (e.g., | Yes |
| String | Name of the share from the provider account | Yes |
<?xml version="1.0" encoding="UTF-8"?>
<databaseChangeLog
xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:pro-snowflake="http://www.liquibase.org/xml/ns/pro-snowflake"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog
http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-latest.xsd
http://www.liquibase.org/xml/ns/pro-snowflake
http://www.liquibase.org/xml/ns/pro-snowflake/liquibase-pro-snowflake-latest.xsd">
<!-- Create database from share with legacy locator -->
<changeSet id="create-database-from-share-basic" author="examples">
<pro-snowflake:createDatabaseFromShare
databaseName="SHARED_SALES_DATA"
providerAccount="xy12345"
shareName="public_sales_share"/>
</changeSet>
<!-- Create database from share with organization format -->
<changeSet id="create-database-from-share-org" author="examples">
<pro-snowflake:createDatabaseFromShare
databaseName="PARTNER_DATA"
providerAccount="myorg.account1"
shareName="analytics_share"/>
</changeSet>
<!-- Create database from share with cloud region -->
<changeSet id="create-database-from-share-region" author="examples">
<pro-snowflake:createDatabaseFromShare
databaseName="EXTERNAL_DATA"
providerAccount="xy12345.us-east-1.aws"
shareName="market_data"/>
</changeSet>
</databaseChangeLog>