Practical reference for daily usage

dbterm guide

This page documents the real app workflow from connection setup to production-safe operations. Keep it open while onboarding new users.

Setup + workflow Keybindings by context Services + backup actions Troubleshooting tips

1. Start in 60 seconds

Install, connect, run SQL, then iterate in panel-focused flow.

Install on Linux / macOS

curl -fsSL https://raw.githubusercontent.com/shreyam1008/dbterm/main/install.sh | bash

Install on Windows

powershell -NoProfile -ExecutionPolicy Bypass -Command "irm https://raw.githubusercontent.com/shreyam1008/dbterm/main/install.ps1 | iex"

1. Install dbterm

Use the shell installer for Linux/macOS or PowerShell installer for Windows.

2. Create a connection

Press N in dashboard, select DB type, fill fields, then Save & Connect.

3. Run your first query

Focus Query panel (Alt+Q), type SQL, and press Enter to run.

4. Inspect and iterate

Use Alt+T and Alt+R to move between tables and results while refining SQL.

2. Understand the workspace

dbterm is optimized around panel focus and keyboard flow.

Panel Primary behavior Core keys
Dashboard Manage saved connections, add/edit/remove entries, and reconnect quickly. N, E, D, Enter, R
Query Write SQL and execute it directly against the current database session. Alt+Q, Enter, Shift+Enter
Tables Browse schema objects and load table data into the results pane. Alt+T, F5, Ctrl+F5
Results Sort columns, select multiple rows, export selected/all CSV, inspect rows, and switch fullscreen. Alt+R, S, Space, Alt+A/C/E, Enter, Alt+F, +/−

3. Essential shortcuts

Use these to avoid context switching and keep query loops fast.

Shortcut Action
Alt + Q / T / R Focus Query, Tables, or Results panel
Enter Execute query (in Query panel)
Shift + Enter New line in query (multiline SQL)
Alt + Y Open per-connection query history
Alt + A / Alt + C Select all result rows / clear selection
Space (Results) Toggle current row selection
Alt + E Export selected rows to CSV (or all displayed rows)
Alt + I Open SQL import modal for active connection (PostgreSQL/MySQL)
I (Dashboard) Import SQL dump into selected saved PostgreSQL/MySQL connection
G (Dashboard) / Alt + , Open keymap settings page
Alt + H Toggle help + SQL cheatsheets
Alt + D Back to dashboard
Alt + S Open services dashboard
F5 / Ctrl + F5 Refresh current table / refresh list + table
Alt + F Toggle fullscreen results
Alt + B Open backup modal (PostgreSQL/MySQL)
Alt + = / - / 0 Adjust preview row limit
Ctrl + = / - Zoom table columns wider / narrower
Ctrl + 0 Reset zoom to default
+ / - Widen / narrow selected column (in Results)
Ctrl + C Quit app

Use Esc and Backspace to back out safely from most views if you lose focus.

4. Services and backup workflow

Useful when dbterm is part of local infra maintenance or incident response.

Inspect service state

Press Alt+S from anywhere to view MySQL/PostgreSQL status and quick actions.

Toggle MySQL/PostgreSQL

Inside services, use key 1 for MySQL and key 2 for PostgreSQL start/stop.

Connect directly from services

Use C or Enter to open connect modal with prefilled defaults.

Backup active database

Press Alt+B from workspace to open backup flow for PostgreSQL/MySQL.

Import SQL dumps safely

Press Alt+I in workspace or I on Dashboard, provide a .sql path, and dbterm streams psql/mysql output. Use Esc/Ctrl+C during run to request cancel.

5. CLI maintenance reference

Use CLI mode for updates, diagnostics, and uninstall operations.

CLI command set

dbterm
dbterm --help
dbterm --version
dbterm --info
dbterm --update
dbterm --update X.Y.Z
dbterm --uninstall
dbterm --uninstall --purge
dbterm --uninstall --yes
Command Purpose
dbterm Launch interactive TUI
dbterm --help Show command help
dbterm --version Show version + build details
dbterm --info Show install path, config path, and runtime info
dbterm --update Update to latest release
dbterm --update X.Y.Z Update to a specific release
dbterm --uninstall Uninstall binary with confirmation
dbterm --uninstall --purge Uninstall binary + saved connections
dbterm --uninstall --yes Uninstall without prompt

6. Troubleshooting quick list

7. Interface preview

Screenshot is placed at the end so the guide stays task-focused first.

dbterm main interface with tables and SQL query editor