Skip to content

Commit

Permalink
Add retry columns to query_history_enriched
Browse files Browse the repository at this point in the history
  • Loading branch information
jessica-larson-sh committed Jan 28, 2025
1 parent 020a4ac commit 5bb1967
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
7 changes: 6 additions & 1 deletion models/query_history_enriched.sql
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,12 @@ select
query_history.transaction_blocked_time / 1000 as transaction_blocked_time_s,
query_history.list_external_files_time / 1000 as list_external_files_time_s,
query_history.execution_time / 1000 as execution_time_s,
cost_per_query.currency
cost_per_query.currency,
query_history.query_retry_time as query_retry_time_ms,
query_history.query_retry_time / 1000 as query_retry_time_s,
query_history.query_retry_cause as query_retry_cause,
query_history.fault_handling_time as fault_handling_time_ms,
query_history.fault_handling_time / 1000 as fault_handling_time_s

from query_history
inner join cost_per_query
Expand Down
10 changes: 10 additions & 0 deletions models/query_history_enriched.yml
Original file line number Diff line number Diff line change
Expand Up @@ -197,3 +197,13 @@ models:
description: Contains the original query text stripped of any comments.
- name: dbt_metadata
description: Metadata from the JSON string added to the query by dbt. Null if no metadata was added.
- name: query_retry_time_ms
description: Total execution time (in milliseconds) for query retries caused by actionable errors.
- name: query_retry_time_s
description: Total execution time (in seconds) for query retries caused by actionable errors.
- name: query_retry_cause
description: Error that caused the query to retry. If there is no query retry, the field is NULL.
- name: fault_handling_time_ms
description: Total execution time (in milliseconds) for query retries caused by errors that are not actionable.
- name: fault_handling_time_s
description: Total execution time (in seconds) for query retries caused by errors that are not actionable.

0 comments on commit 5bb1967

Please sign in to comment.