Created
April 10, 2020 04:59
-
-
Save vvgsrk/54182732822350cbb0a3d3fe04ce3dba to your computer and use it in GitHub Desktop.
1 Hour Interval Average Load
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT DATE_TRUNC('hour', start_time) start_time_trunced_at_hour, | |
HOUR(start_time) start_time_hour, | |
AVG(avg_running) avg_running, | |
AVG(avg_queued_load) avg_queued_load, | |
AVG(avg_queued_provisioning) avg_queued_provisioning, | |
AVG(avg_blocked) avg_blocked | |
FROM snowflake.account_usage.warehouse_load_history | |
WHERE DATE_TRUNC('DAY', start_time) = '2020-03-17' | |
AND warehouse_name = 'PUT_YOUR_WAREHOUSE_NAME' | |
GROUP BY start_time_trunced_at_hour, start_time_hour | |
ORDER BY start_time_trunced_at_hour; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment