-
Notifications
You must be signed in to change notification settings - Fork 0
Getting Started
Berkay Günaydın edited this page Aug 6, 2026
·
1 revision
Five minutes to your first multi-server query.
propq reads server connections from a TOML file. The search order is:
-
-c PATH(explicit flag) -
./propq.toml(current directory) -
~/.config/propq/config.toml(platform config dir)
Generate one:
propq config generate -o propq.tomlor copy the repo's example:
cp propq.toml.example propq.tomlEdit it and add your servers:
[connections.local]
host = "127.0.0.1"
port = 3306
user = "myuser"
password = "mypassword"
max_connections = 3
tags = ["dev"]
[connections.prod-eu-1]
host = "db1.example.com"
port = 3306
user = "myuser"
password = "mypassword"
max_connections = 3
tags = ["prod", "eu"]# List servers and their live database counts
propq servers
# Validate config + test every connection
propq config checkDefault mode: once per server — fast (~50 ms per server), uses the server's default database:
propq -s local --sql "SELECT VERSION(), NOW()"Per-database mode (every matching database on every matching server):
propq -s local -a -d "^test" --sql "SELECT COUNT(*) FROM users"# Inline
propq --sql "SELECT 1" -s prod
# File (use '-' for stdin)
propq -f migration.sql -d "^shop_"
# Pipe
echo "SELECT NOW(), DATABASE()" | propq -s staging
# Editor ($EDITOR) — with query history support
propq -eSQL source priority: --sql → -f → -e → stdin pipe.
propq -s prod --sql "SELECT VERSION()" # table (auto-paged via less)
propq -s prod --sql "SHOW TABLE STATUS" --json # JSON for scripts/AI
propq -s prod --sql "SELECT * FROM users" --csv # CSV for Excel
propq -s prod --sql "SELECT 1" --stream # results as they completeLong table output auto-pages through less -SRFX when stdout is a TTY — search with /, quit with q. Disable with --no-pager.
- Configuration — every config key
- CLI-Reference — all flags
- Examples — ready-to-use commands
This wiki is community-maintained. Found something outdated? Open an issue on the repository.
propq — Async SQL executor for MySQL/MariaDB
- Home
- Installation
- Getting-Started
- Configuration
- CLI-Reference
- Output-Formats
- Safety
- Examples
- AI-Agents
- Development
External links