Skip to content

Latest commit

 

History

History
137 lines (90 loc) · 3.47 KB

export-import.md

File metadata and controls

137 lines (90 loc) · 3.47 KB

Export and import

Current query

Export the result of the SQL currently displayed in the main table.

Access via Gear → Export → Current query as:

Format Notes
Parquet Full result set in columnar Parquet format
CSV Prompts for delimiter (comma, semicolon, tab, pipe, custom)
SQLite Single result table in a new SQLite file
DuckDB Single result table in a new DuckDB file

All exports are written directly by DuckDB's COPY … TO statement — no in-memory round-trip.

CSV delimiter dialog

When exporting as CSV, a dialog prompts you for the delimiter:

Option Character
Comma (default) ,
Semicolon ;
Tab \t
Pipe |
Other… Any single character

All queries (pinned)

Export all pinned queries at once.

Access via Gear → Export → All queries as:

Format What is exported
DuckDB Each pinned query is executed and saved as a table named after the query's name
SQLite Same as DuckDB but in a SQLite file
SQL The query SQL only (no data) — one -- name comment + SQL statement per query

Example: exporting as SQL

Given two pinned queries named monthly_revenue and top_customers:

-- monthly_revenue
SELECT date_trunc('month', created_at) AS month, SUM(amount) AS revenue
FROM orders GROUP BY 1 ORDER BY 1;

-- top_customers
SELECT customer_id, SUM(amount) AS total
FROM orders GROUP BY 1 ORDER BY 2 DESC LIMIT 20;

Example: exporting as DuckDB

Running the above produces a results.duckdb file with:

  • Table monthly_revenue containing the full result
  • Table top_customers containing the full result

Session export (archive)

Export the current session state + referenced local files as a self-contained .tar.gz:

Gear → Sessions → Export as…

Or from the Session Manager: click Export next to a saved session.

Archive contents

session.json          ← full SessionState JSON
prefs.json            ← profile preferences snapshot
files/
  0_sales.parquet     ← copy of each referenced local file
  1_customers.csv
  …

Remote file URLs are preserved as-is (not downloaded into the archive).


Session import (archive)

Gear → Sessions → Load from…

Accepts .tar.gz or .tgz. On import:

  1. Files are extracted to a temp directory
  2. Paths in the session state are rewritten to the extracted locations
  3. If issues are found, the Session Warning dialog appears

Notes export

In the sidebar Notes section, click ⬇ to open the export dropdown:

Format Notes
Markdown (.md) Each note is a ## Title section separated by ---
Text (.txt) Each note is a === Note N: Title === section
PDF (.pdf) Multi-page PDF with title, date, and body rendered from Markdown

Markdown export example

## Monthly Analysis
_7/3/2026, 10:41:22 AM_

Revenue grew 12% month-over-month.

TVQuery[monthly_revenue]

---

## Customer Notes
_7/3/2026, 11:00:00 AM_

Top 20 customers account for 68% of revenue.

Notes import

Click ⬆ in the Notes section header:

  • .md files — each ## Heading becomes a separate note; content between headings becomes the note body
  • .txt files — the entire file becomes a single note with the filename as the title

Imported notes are added to the current session (existing notes are not replaced).