The "History" panel lists the statements executed in this session, whichever document they were executed from, with what each of them cost. It is one panel for the whole window:
![[20260903-qt-history.png]]
The history outlives the session. It is kept per user in `sqlhistory.json` in `%USERPROFILE%\Invantive\Prd\Invantive Query Tool` and is read again at the next start, up to the 2,500 most recently executed statements.
## Columns
Every row is one statement, and a statement executed again keeps its row and counts up:
- "Clock Time", "CPU Time", "I/O Time" and "Sleep Time": what the last execution cost, in milliseconds. Sleep time is time spent waiting on a platform which asked to be called back later, such as a rate limit.
- "Rows Affected": the number of rows the last execution returned or changed.
- "I/O Calls" and "Partitions": the number of calls to the platform and the number of partitions addressed.
- "Execution Start (UTC)" and "First Time Started (UTC)": when the last and the first execution began.
- "#Executions" and the four "Total" columns: how often the statement was executed and what it cost over all executions together.
- "Successful" and "In Progress": whether the last execution completed without an error, and whether it is still running.
- "Name": the name given to the statement, see below.
- "SQL Text": the statement itself, shown on one line.
## Actions
The toolbar carries "Export", which writes the history to a file in the formats of [[Invantive Script/Invantive Script|Invantive Script]].
The context menu of a row holds:
- "Copy query": place the statement on the clipboard.
- "Add to Named SQLs": give the statement a name, which is then shown in the "Name" column. A name is unique within the history: giving a name which another statement already carries moves it.
## Searching
From release 27.0 onwards the toolbar carries a search field which leaves only the statements whose text holds the text searched for:
![[20260903-qt-history-search.png]]
The statement is searched as it was written, line breaks and all, and upper and lower case are treated alike. The button behind the field empties it, as does the Escape key. See [[Invantive Query Tool/Main Window#Searching in a panel|Searching in a panel]] for the search fields of the other panels.