QueryDeck Docs
Browse and edit data

Export data

CSV, JSON, SQL inserts, and Excel from any result grid or full table.

For: analysts, developers, anyone who needs to hand data off.

QueryDeck exports from two places: a query result, and a full table. Both support the same four formats.

Export formats

FormatBest forNotes
CSVSpreadsheets, Excel, Google SheetsConfigurable delimiter, quoting, header row
JSONAPIs, JavaScript tools, data pipelinesArray of objects, one per row
SQLDatabase-to-database migrationINSERT statements with explicit columns
Excel (.xlsx)Sharing with non-technical teammatesOne sheet per result, types preserved

Export from a query result

After running a query, the result grid has an Export button in the top-right of the result pane. Click it.

A sheet opens with format + options:

  • Format — pick one of CSV, JSON, SQL, Excel.
  • Rows to exportAll rows (re-runs the query without LIMIT), Visible rows (just what's loaded), Selected rows (the ones you've highlighted).
  • Format-specific options (see below).

Choose a destination, save. The file lands on disk and Finder opens to it.

Export a full table

In Table Mode, click Export in the table toolbar. Same sheet, same options, but All rows means the entire table — filters applied if any are active.

For very large tables (millions of rows), the export streams to disk as it reads from the database. Memory usage stays low. The progress bar tells you how many rows are done.

CSV options

OptionDefaultNotes
Delimiter,Use ; for European locales, \t for TSV
Quote character"Standard CSV quoting
Quote styleMinimalQuote only when needed, or always quote
Header rowOnInclude column names as the first line
NULL representationemptyOr a literal string like NULL if your downstream tool needs it
Line ending\nOr \r\n for Windows compatibility
EncodingUTF-8UTF-8 with BOM available for Excel compatibility

JSON options

OptionDefaultNotes
FormatArray of objectsOr one object per line (newline-delimited JSON) for streaming
IndentPretty (2 spaces)Or compact for minimal file size
NULL representationnullOr omit the key entirely
Date formatISO 8601Or Unix timestamp

SQL options

OptionDefaultNotes
Statement typeINSERTOr INSERT ... ON CONFLICT DO NOTHING for idempotent imports
Batch size100 rows per statementLarger batches are faster but harder to debug
Table nameThe source tableOverride to retarget the inserts elsewhere
Include schemaOffPrefix with public. or your schema name

Excel options

OptionDefaultNotes
Sheet nameResult name or table name
Number formatGeneralOr specify a format string per column
Date formatLocale default
Boolean asTRUE/FALSEOr 1/0

Excel files preserve column types — booleans become real Excel booleans, dates become real Excel dates.

Copy as

For a single row or selection, you don't need a file. Right-click in the grid → Copy as:

Copy asWhat goes on the clipboard
Cell valueThe raw value, no formatting
Tab-separated rowPaste straight into a spreadsheet
CSV lineComma-separated, ready for a CSV file
JSON object{ "col1": "value1", "col2": 123 }
INSERT statementINSERT INTO table (col1, col2) VALUES ('value1', 123);

Cmd+Shift+C is the shortcut for "Copy as INSERT", the most common case during development.

Export pending changes as SQL

When you've edited rows in Table Mode but haven't committed yet, the pending changes bar has an Export to .sql button. The file contains the exact INSERT, UPDATE, DELETE statements that would run on commit.

Useful for:

  • Running the same change on staging before committing on production.
  • Code review with a teammate.
  • Auditing what an edit session would change.

Limitations

  • Excel has a hard cap of 1,048,576 rows per sheet. QueryDeck splits across sheets if you exceed it.
  • SQL exports are not minified or escape-optimized. For very large data dumps, use pg_dump or mysqldump instead.
  • Binary columns (bytea, BLOB) are exported as base64 in JSON, as escaped strings in CSV, and as decode('...', 'base64') in SQL.

What's next