vi-sql logo

Development Route

Planned milestones in implementation order. Each stop represents a shippable improvement.

origin
01
schema

Schema Tree: Procedures, Triggers & Functions

Views now surface in the schema tree. Extend it further to show materialized views, procedures, triggers, sequences, and functions as separate child nodes. Read-only metadata — no DDL risk.

02
editor

Vim Mode: Search, Indent & Text Objects

Counts (3w, 5dd) and multi-key sequences already landed. Add ?, n, N for search; >> / << for indent/dedent; text objects like `ciw` / `diw`; % to jump matching paren.

03
query results

Editable Query Results

For simple single-table SELECT (no joins, aggregates, CTEs), enable inline CRUD using the source table from FieldDescription.TableOID. Complex queries stay read-only with a clear indicator. v1 Postgres only.

04
ux & sessions

Transaction Mode

Explicit BEGIN / COMMIT / ROLLBACK per tab with a visual badge in the tab title. Today every query autocommits. Blocks tab close with an unsaved transaction.

05
connectivity

TiDB Driver

MySQL-protocol compatible. Minimal new code on top of the existing MySQL driver.

06
query results

Query Plan Cost Warnings

Color-code nodes in the EXPLAIN viewer: seq scan on high row estimates → yellow, expensive loops → red. Summary line at top. Thresholds configurable per-connection.

07
query results

Consider: Search Within Results

Search in table view: overlay input bar, highlight matching cells, n/N to jump. Case-insensitive default, optional regex. Scoped to the currently loaded batch in v1.

08
ux & sessions

Query Templates: Save & Run

JSON file in config dir. Save the current buffer with a name and optional tags. History-modal-style window lists saved templates — pick one to load or run instantly. :w <name> in vim mode maps to save.

09
editor

Query Templates: Variable Substitution

Fill {{ var }} placeholders via a pre-run prompt before executing a saved template. Uses bind parameters by default; text substitution only for identifiers (table/column names) where bind params aren't valid.

10
ux & sessions

--mcp Flag: Standalone MCP Server Mode

Add a --mcp flag to launch only the MCP server without starting the full TUI. Requires a connection selection step at startup — pick from already registered connections — so the correct driver is loaded before the server begins accepting requests.

11
ux & sessions

Tab / Session Persistence

On clean exit, persist open query tabs per connection — buffer text, active tab, cursor offset. Restore on reconnect.

12
editor

Consider: Vim Mode in Other Inputs

Extend vim coverage to schema-tree filter bar, inline edit modals, value editors, and peeker — or document the scope explicitly so users are not surprised.

13
connectivity

DuckDB Driver

Standard SQL (PostgreSQL dialect), schemas, DDL, indexes. go-duckdb driver exists. Embedded like SQLite — no network connection needed. Ideal for local analytics workflows.

14
query results

Result Row to INSERT Statement

Copy a selected row as an INSERT INTO ... VALUES (...) statement to clipboard. Same code path as SQL export, scoped to one row.

15
query results

Result Set Diffing

Snapshot current result, run a variant query, show rows added/removed/modified and exec-time delta. Niche but powerful for verifying index changes.

16
connectivity

Oracle Driver

SQL-shaped but quirky DDL — ROWNUM vs LIMIT, non-standard type names. godror requires Oracle client libraries, which adds deployment overhead.

17
connectivity

SSH Tunneling

Add SSH tunnel config (host, port, user, password or key file) to SQLConfig and thread it through the connection flow. Lets users reach databases on private networks without a separate tunnel process. No other client offers this in a TUI.

18
connectivity

ClickHouse Driver

HTTP and native protocols supported by clickhouse-go. Column-oriented semantics differ from row DBs — EXPLAIN output and type mapping need special handling.

19
connectivity

Snowflake Driver

gosnowflake is the standard driver. Auth via username/password or key-pair; virtual warehouse and role are connection-level settings added to SQLConfig.

20
connectivity

BigQuery Driver

cloud.google.com/go/bigquery or the community go-sql-driver/bigquery. Auth via Application Default Credentials or a service-account key. Project and dataset replace the traditional database/schema hierarchy.

planned