Snowflake Management, Governance & Collaboration
Emily Melhuish
Technical Curriculum Developer, Snowflake
![]()
ALTER_ACCOUNT
| Level | Description |
|---|---|
| TRACE | Every function entry and exit — most granular |
| DEBUG | Diagnostic detail |
| INFO | Normal execution milestones — recommended for production |
| WARN | Unexpected conditions that did not stop execution |
| ERROR | Failures |
| FATAL | Critical failures that halted execution |

SELECT user_name,
event_timestamp,
client_ip,
authentication_method,
error_code,
error_message
FROM SNOWFLAKE.ACCOUNT_USAGE.LOGIN_HISTORY
WHERE event_timestamp >= DATEADD('day', -90, CURRENT_TIMESTAMP())
AND client_ip NOT LIKE '203.0.113.%'
ORDER BY event_timestamp DESC;
SELECT user_name,
role_name,
warehouse_name,
query_text,
start_time,
end_time
FROM SNOWFLAKE.ACCOUNT_USAGE.QUERY_HISTORY
WHERE start_time >= DATEADD('day', -90, CURRENT_TIMESTAMP())
AND query_text ILIKE '%credit_scores%'
ORDER BY start_time DESC;
| Source | What it captures | Audit question answered |
|---|---|---|
| Event table | Logs and traces from stored procedures, Snowpark functions | What did the platform do? |
| LOGIN_HISTORY | Every login attempt: user, IP, method, errors | Who connected, from where, did anything fail? |
| QUERY_HISTORY | Every SQL statement: user, role, warehouse, query text | What data was touched, and by whom? |
Snowflake Management, Governance & Collaboration