Data Sharing In Snowflake

Sharing data in Snowflake is simple and convenient between accounts. When data is securely shared between accounts, the data is not physically moved to the shared account. Since data is not physically moved, there are no storage costs incurred by the shared account. The shared account will incur costs only when querying the shared data (and utilises the compute resources).


How does data sharing work

The provider (entity sharing the data) creates a share of one or more databases belonging to the same Snowflake account and makes the database objects available for the consumer. The consumer (entity that the data is shared with), gets access to the database objects as a read-only privilege. This means the consumer can query data but not make changes to the database objects. When new objects are added to the share, then the data immediately becomes available to the consumers of the share. Access to the share can also be revoked at any time as per the providers discretion.


Data Share Types

Data can be shared by the following ways:

  1. A Listing: A share and additional metadata are shared to one or more accounts.
  2. Direct Share: Database objects are shared directly to another account in your region.
  3. Data Exchange: You set up and manage a group of accounts and offer a share to that specific group.


Data Share Participants

Provider

A provider is the entity that creates the share and makes this share available to other accounts for consumption. Providers have full control of the contents of the share, they have access to when the shared data can be revoked and determines the accounts to be shared.

 

Consumer

Consumers are the entities that the providers share data with, and it is important to note that the data is still physically stored on the Providers account. The consumer is only able to query the shared data and is charged for this feature (querying via compute resources).

 

Reader Accounts for Third-Party Access

Reader accounts makes it possible for providers to share data with Non-Snowflake users. Reader accounts belong to the provider and these accounts can only consume data from the provider account that created it.

A video demonstration on setting up a Direct Share:

A video demonstration on setting up a Reader Account: