Skip to content

Add Snowflake best practices rules#30

Open
jamescha-earley wants to merge 1 commit into
sanjeed5:mainfrom
jamescha-earley:add-snowflake-rules
Open

Add Snowflake best practices rules#30
jamescha-earley wants to merge 1 commit into
sanjeed5:mainfrom
jamescha-earley:add-snowflake-rules

Conversation

@jamescha-earley

Copy link
Copy Markdown

Summary

  • Add snowflake entry to rules.json with database/data-warehouse/cloud/sql/analytics tags
  • Add rules-mdc/snowflake.mdc with comprehensive Snowflake best practices

What the rules cover

  • SQL fundamentals: naming conventions, CTEs, MERGE, stored procedures (colon prefix for variables)
  • Semi-structured data: VARIANT/OBJECT/ARRAY, FLATTEN, null handling
  • Performance: cluster keys, Search Optimization Service, warehouse sizing
  • Data pipelines: Dynamic Tables, Streams+Tasks, Snowpipe (with decision table for choosing approach)
  • Cortex AI Functions: all 13 AI_* functions, models, examples, cost awareness
  • Cortex Search: CREATE SERVICE syntax (single/multi-index), Python query API, RAG pattern
  • Snowpark Python: Session, DataFrame API, scalar vs vectorized UDFs, stored procedures
  • dbt on Snowflake: dynamic_table materialization, Snowflake-specific configs
  • Security: RBAC, masking policies, credential management
  • Common pitfalls: anti-patterns across all areas

All content grounded in official Snowflake documentation.

.... Generated with Cortex Code

Add comprehensive Snowflake .mdc rules covering SQL, data pipelines
(Dynamic Tables, Streams, Tasks, Snowpipe), Cortex AI Functions,
Cortex Search for RAG, Snowpark Python, and dbt integration.

.... Generated with Cortex Code (https://docs.snowflake.com/en/user-guide/cortex-code/cortex-code)

Co-Authored-By: Cortex Code <noreply@snowflake.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant