Examine SQL Queries (Workbooks)
Sigma’s Query history modal is a powerful tool if you want to better understand your Sigma generated SQL queries.
The modal displays an overview of recent queries, their runtime and current status. You can deep dive into individual queries to view their underlying SQL or investigate errors.
Summary of Content
View Recent Queries
View an Individual Query
Query Status Types
Query Runtime Breakdown
Pause and Resume Queries
Related Resources
View Recent Queries
The query history modal displays recent queries run from your open document within the existing session.
Your document’s individual query list will automatically show each query’s status, action type, start time and run time.
-
Click the caret (▼) button next to the refresh data button in the workbook's header.
-
Click Query history.
View an Individual Query
- Click the care (▼) button next to the refresh data icon button in the workbook's header.
- Click Query history....
- Click the query you would like to learn more about.
- Explore the query detail view:
- View and copy the Sigma generated SQL.
- If the query failed, an error will also be displayed below Query Details.
Query Status Types
Symbol |
Status |
Description |
![]() |
Completed |
Your query ran successfully! |
![]() |
Running |
Your query is currently running. |
![]() |
Errored |
Something went wrong. |
![]() |
Paused |
Queries are paused on your document. |
![]() |
Canceled |
The query has been canceled. |
Query Runtime Breakdown
A detailed query runtime breakdown is available for successfully completed and timed out queries. Query runtimes can vary due to network traffic, queue delay, or data warehouse processing time. Sigma’s runtime breakdown allows you to see if and when your query encountered delays.
The runtime is broken into three parts:
- Queue Duration: the amount of time the query sits in Sigma’s queue prior to being sent to the warehouse.
- Sigma runtime: the amount of time Sigma takes to process the query, excluding queue duration and warehouse time.
- Warehouse runtime: the amount of time between when Sigma sends a request to your data warehouse and when it gets a response back. This is roughly the amount of time the warehouse spent running your query.
Note: Incomplete queries do not display a detailed runtime breakdown. This feature is also not available for download/export requests.
Pause and Resume Queries
You can pause queries to make changes to your document without automatically running queries against your warehouse.
-
Click the caret icon next to the refresh/play button all the way to the left in your dataset’s toolbar.
-
Click Pause queries or Resume queries.