0
0
Snowflakecloud~30 mins

Data classification and tagging in Snowflake - Mini Project: Build & Apply

Choose your learning style9 modes available
Data Classification and Tagging in Snowflake
📖 Scenario: You work as a data engineer in a company that uses Snowflake to store data. Your team wants to organize data better by classifying tables and tagging them with important labels like 'PII' (personally identifiable information) or 'Finance'. This helps everyone find and protect sensitive data easily.
🎯 Goal: Build a Snowflake setup where you create a table, define classification tags, and assign those tags to the table to mark its data type.
📋 What You'll Learn
Create a table named customer_data with columns id (integer) and email (string).
Create a tag named data_classification with allowed values 'PII' and 'Non-PII'.
Assign the tag data_classification with value 'PII' to the customer_data table.
💡 Why This Matters
🌍 Real World
Classifying and tagging data helps companies manage sensitive information securely and comply with regulations.
💼 Career
Data engineers and cloud architects often organize data with tags to improve data governance and security.
Progress0 / 4 steps
1
Create the customer_data table
Write a Snowflake SQL statement to create a table called customer_data with two columns: id as INTEGER and email as STRING.
Snowflake
Need a hint?

Use CREATE TABLE followed by the table name and column definitions inside parentheses.

2
Create the data_classification tag
Write a Snowflake SQL statement to create a tag called data_classification with allowed values 'PII' and 'Non-PII'.
Snowflake
Need a hint?

Use CREATE TAG with ALLOWED_VALUES to specify the possible tag values.

3
Assign the data_classification tag to the customer_data table
Write a Snowflake SQL statement to assign the tag data_classification with value 'PII' to the customer_data table.
Snowflake
Need a hint?

Use ALTER TABLE with SET TAG to assign the tag value.

4
Verify the tag assignment
Write a Snowflake SQL query to show the tags assigned to the customer_data table.
Snowflake
Need a hint?

Use SHOW TAGS ON TABLE followed by the table name to see assigned tags.