snowflake-advanced-troubleshooting

Featured

Apply advanced Snowflake debugging with query profiling, spill analysis, lock contention, and performance deep-dives using ACCOUNT_USAGE views. Use when standard troubleshooting fails, investigating slow queries, or diagnosing warehouse performance issues. Trigger with phrases like "snowflake hard bug", "snowflake slow query debug", "snowflake query profile", "snowflake spilling", "snowflake deep debug".

AI & Automation 2,266 stars 315 forks Updated today MIT

Install

View on GitHub

Quality Score: 99/100

Stars 20%
100
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Snowflake Advanced Troubleshooting ## Overview Deep debugging techniques for complex Snowflake issues: query profile analysis, spill detection, lock contention, transaction conflicts, and metadata operation bottlenecks. ## Instructions ### Step 1: Query Profile Deep Dive ```sql -- Get detailed execution stats for a specific query SELECT * FROM TABLE(GET_QUERY_OPERATOR_STATS('<query_id>')); -- Key operators to look for: -- TableScan: Check partitions_scanned vs partitions_total -- Sort: Check spilling_to_local_storage, spilling_to_remote_storage -- Join: Check type (broadcast vs hash), probe/build side sizes -- Aggregate: Check if grouping cardinality causes spill -- Identify queries with excessive spilling SELECT query_id, query_text, bytes_spilled_to_local_storage / 1e9 AS local_spill_gb, bytes_spilled_to_remote_storage / 1e9 AS remote_spill_gb, total_elapsed_time / 1000 AS seconds, warehouse_size FROM SNOWFLAKE.ACCOUNT_USAGE.QUERY_HISTORY WHERE (bytes_spilled_to_local_storage > 0 OR bytes_spilled_to_remote_storage > 0) AND start_time >= DATEADD(hours, -24, CURRENT_TIMESTAMP()) ORDER BY bytes_spilled_to_remote_storage DESC LIMIT 20; -- Remote spill = warehouse too small for the query -- Fix: Scale up warehouse or optimize query to reduce intermediate data ``` ### Step 2: Lock and Transaction Contention ```sql -- Find blocked/waiting queries SELECT query_id, query_text, blocked_query_id, DATEDIFF('second', start_time, CURRENT_T...

Details

Author
jeremylongshore
Repository
jeremylongshore/claude-code-plugins-plus-skills
Created
7 months ago
Last Updated
today
Language
Python
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category

AI & Automation Featured

snowflake-debug-bundle

Collect Snowflake debug evidence for support tickets and troubleshooting. Use when encountering persistent issues, preparing support cases, or collecting diagnostic information from QUERY_HISTORY and ACCOUNT_USAGE. Trigger with phrases like "snowflake debug", "snowflake support bundle", "snowflake diagnostic", "snowflake query history", "snowflake troubleshoot".

2,266 Updated today
jeremylongshore
AI & Automation Solid

snowflake-performance-tuning

Optimize Snowflake query performance with clustering, materialized views, caching, and query profiling. Use when queries are slow, analyzing QUERY_HISTORY for bottlenecks, or optimizing warehouse utilization and data scanning. Trigger with phrases like "snowflake performance", "optimize snowflake", "snowflake slow query", "snowflake clustering", "snowflake query profile".

2,266 Updated today
jeremylongshore
AI & Automation Solid

snowflake-observability

Set up Snowflake observability using ACCOUNT_USAGE views, alerts, and external monitoring. Use when implementing Snowflake monitoring dashboards, setting up query performance tracking, or configuring alerting for warehouse and pipeline health. Trigger with phrases like "snowflake monitoring", "snowflake metrics", "snowflake observability", "snowflake dashboard", "snowflake alerts".

2,266 Updated today
jeremylongshore
AI & Automation Featured

snowflake-known-pitfalls

Identify and avoid Snowflake anti-patterns and common mistakes in SQL, warehouse management, data loading, and access control. Use when reviewing Snowflake configurations, onboarding new users, or auditing existing Snowflake deployments for best practices. Trigger with phrases like "snowflake mistakes", "snowflake anti-patterns", "snowflake pitfalls", "snowflake what not to do", "snowflake code review".

2,266 Updated today
jeremylongshore
AI & Automation Solid

snowflake-rate-limits

Handle Snowflake concurrency limits, warehouse queuing, and query throttling. Use when queries are queuing, hitting concurrency limits, or needing to optimize warehouse sizing for throughput. Trigger with phrases like "snowflake rate limit", "snowflake throttling", "snowflake queuing", "snowflake concurrency", "snowflake warehouse sizing".

2,266 Updated today
jeremylongshore