| name | snowflake-data-handling |
| description | Implement Snowflake data governance with masking policies, row access policies,
tagging, and GDPR/CCPA compliance patterns.
Use when handling PII, implementing column masking, configuring data classification,
or ensuring compliance with privacy regulations in Snowflake.
Trigger with phrases like "snowflake data governance", "snowflake masking",
"snowflake PII", "snowflake GDPR", "snowflake row access policy", "snowflake tags".
|
| allowed-tools | Read, Write, Edit |
| version | 1.5.0 |
| license | MIT |
| author | Jeremy Longshore <jeremy@intentsolutions.io> |
| tags | ["saas","data-warehouse","analytics","snowflake"] |
| compatibility | Designed for Claude Code |
Snowflake Data Handling
Overview
Implement data governance in Snowflake using column-level masking policies, row access policies, object tagging, and data classification for GDPR/CCPA compliance.
Prerequisites
- Enterprise Edition or higher (for masking and row access policies)
- SECURITYADMIN or ACCOUNTADMIN role
- Understanding of GDPR/CCPA data subject rights
Instructions
Step 1: Data Classification with Tags
CREATE TAG IF NOT EXISTS pii_type
ALLOWED_VALUES 'email', 'phone', 'ssn', 'name', 'address';
CREATE TAG IF NOT EXISTS data_sensitivity
ALLOWED_VALUES 'public', 'internal', 'confidential', 'restricted';
ALTER TABLE users MODIFY COLUMN email SET TAG pii_type = 'email';
ALTER TABLE users MODIFY COLUMN phone SET TAG pii_type = 'phone';
ALTER TABLE users MODIFY COLUMN name SET TAG pii_type = 'name';
ALTER TABLE users MODIFY COLUMN email SET TAG data_sensitivity = 'confidential';
SELECT * FROM (INFORMATION_SCHEMA.TAG_REFERENCES(
,
));
(
INFORMATION_SCHEMA.EXTRACT_SEMANTIC_CATEGORIES()
);