QueryDeck Docs
Querying

Query history

Every query you run is saved. Find it later, re-run it, or pull it into a new tab.

For: analysts and developers.

QueryDeck records every query you execute, along with the connection it ran on, the time, the row count, and whether it succeeded. History is searchable, filterable, and one click away.

Open history

Way to openWhere
SidebarHistory section, expand any connection
Command paletteCmd+K, type "history"
MenuViewShow History

History is per-connection. If you ran a query on staging, it shows up under staging, not production.

Search and filter

The history panel has a search field at the top:

  • Free text — matches any substring in the SQL.
  • status:success — only completed queries.
  • status:error — only failures, useful to find that one typo from yesterday.
  • Time filters in the dropdown: last hour, today, last 7 days, last 30 days, all time.

Results are sorted newest first. Each row shows:

  • The first line of the SQL (truncated if long)
  • The relative time (5 min ago, yesterday)
  • The row count or the error message
  • The duration of the query

Re-run a query

Double-click any history entry to load it into a new editor tab. The connection is selected automatically. Edit if you want, then Cmd+Return to run.

To pull a query into your current tab instead of opening a new one, right-click and choose Insert at Cursor.

Promote to a saved query

If a query is useful enough to keep, right-click it in history and choose Save Query.... The save dialog opens pre-filled with the SQL. Add a name, tags, optional description, save. The query now lives in Saved Queries and the history entry is still there.

What history stores

StoredNot stored
The exact SQL you ranThe result rows
The connection identifierYour password
Timestamp, duration, row countAnything from queries marked "private" (see below)
Success or error message

History stays on your Mac. Nothing is sent to QueryDeck servers.

Mark a query as private

Some queries hit data you don't want logged on disk, even on your own machine. Prefix the query with --private on the first line:

--private
SELECT password_hash FROM users WHERE email = 'me@example.com';

QueryDeck recognizes the marker and skips writing the query to history. The result still appears in the grid for the current session, but nothing is persisted.

Clear history

SettingsHistory has three buttons:

  • Clear history for this connection
  • Clear all history
  • Export history as CSV — for compliance or audit purposes before clearing

The trial enforces no expiry on history. After the trial, history continues to record but is read-only until you activate a license.

What's next