0
0
Snowflakecloud~30 mins

Why data sharing eliminates data copies in Snowflake - See It in Action

Choose your learning style9 modes available
Why Data Sharing Eliminates Data Copies in Snowflake
📖 Scenario: You work at a company that uses Snowflake for data storage. Different teams need access to the same data without making multiple copies. You will learn how Snowflake's data sharing feature helps share data efficiently.
🎯 Goal: Build a simple Snowflake setup that creates a database, shares data with another account, and shows how data sharing avoids making copies.
📋 What You'll Learn
Create a database called company_data with a table sales
Create a share called sales_share that includes the sales table
Add a consumer account called partner_account to the share
💡 Why This Matters
🌍 Real World
Companies often need to share data securely with partners or other teams without duplicating data. Snowflake's data sharing feature makes this easy and efficient.
💼 Career
Understanding data sharing in Snowflake is important for cloud data engineers and architects to design cost-effective and scalable data solutions.
Progress0 / 3 steps
1
Create the initial database and table
Create a database called company_data and a table called sales with columns id (integer) and amount (number). Insert two rows: (1, 100) and (2, 200).
Snowflake
Need a hint?

Use CREATE DATABASE and CREATE TABLE commands. Insert rows with INSERT INTO.

2
Create a share and add the sales table
Create a share called sales_share and add the sales table from company_data to this share.
Snowflake
Need a hint?

Create the share with CREATE SHARE. Use GRANT USAGE on the database and GRANT SELECT on the table to the share.

3
Add a consumer account to the share
Add the consumer account called partner_account to the share sales_share so it can access the shared data.
Snowflake
Need a hint?

Use ALTER SHARE with ADD ACCOUNTS to add the consumer account.