fix(ingest/snowflake): order queries for queries_v2 (#12551)

This commit is contained in:
Harshal Sheth 2025-02-12 15:10:58 -08:00 committed by GitHub
parent 21496ef9d0
commit fe173faf84
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -731,6 +731,9 @@ fingerprinted_queries as (
JOIN filtered_access_history a USING (query_id) JOIN filtered_access_history a USING (query_id)
) )
SELECT * FROM query_access_history SELECT * FROM query_access_history
-- Our query aggregator expects the queries to be added in chronological order.
-- It's easier for us to push down the sorting to Snowflake/SQL instead of doing it in Python.
ORDER BY QUERY_START_TIME ASC
""" """