Query log

There are times when it may be helpful to view the actual queries that are sent to your database. Chartio allows you to view and download the query log for each connected data source.

View query log

Select Data Sources from the top navigation and choose your data source from the list. Switch to the Query Log tab.

Open the Query Log tab under the data source settings

You’ll be able to view the Start Time, Query SQL, Errors (if any), and Query Duration. Query Duration includes only the time it takes your database to run the query—it does not include chart rendering time. You can also filter by dashboard or chart in the dropdown menus if you’re troubleshooting for a particular chart. The Query column also contains links back to the chart and dashboard.

You can download the query log as a CSV, and even upload it back to Chartio to analyze your query data.

Canceling running queries

Another neat feature of the query log is that it allows you to monitor the duration of any queries that are currently running, and cancel them if desired.

Ocassionally a database does not respond to a cancel query request from Chartio. MySQL, in particular, requires an open connection to send a cancellation request; if there is no open connection available (because many queries are running), the request will be unsuccessful.

Cancel running queries in the query log