dbcodeio/public/dbcode-cli
Claude Code and agent skill by dbcodeio/public
- community
Checking that the SKILL.md file is still in the repository.
Run SQL against connections saved in DBCode using the dbcode command line. Use when a task needs to query, check, or export data from a database the user has set up in DBCode (VS Code, Cursor, Windsurf, or another VS Code fork), run a .sql file, get results as JSON or CSV, or script a database check. Covers finding connections, output formats, non-interactive approvals, and exit codes.
Install
npx vskill@latest install dbcodeio/public/dbcode-cliSKILL.md
DBCode CLI
dbcode runs SQL against the connections the user already saved in DBCode. It reads the same settings as the editor, so there is nothing to configure.
Find the connection first
The cli column says ok or why a connection cannot be opened; some connection types are not available from the CLI yet. Use the connection name with -c, or its id if two connections share a name.
Run a query
SQL comes from the argument, --file, or stdin. If the SQL starts with a -- comment, put a literal -- before it so the parser does not read it as a flag:
Output
- When stdout is not a terminal, output is JSON (one array of row objects per result set) and the CLI never prompts.
--format table|json|jsonl|csv|tsv|markdown. CSV and TSV are byte-identical to the grid's Export.- Only data goes to stdout. Status lines, the row-limit notice, and errors go to stderr, so piping into
jqor a file is safe.
Approvals and safety
The user's environment roles apply exactly as in the editor.
- A statement the role marks "ask" is refused with exit code 4 unless you pass
--yes. - A statement the role denies is refused either way.
- A
DELETEorUPDATEwithout aWHEREclause follows the role's missing-WHERE rule.
Do not pass --yes unless the user asked for that write. Prefer read-only statements for checks.
Other flags
--database and --schema override the connection's defaults. --limit N and --no-limit control the row cap (default: the dbcode.queryRowLimit setting). --timeout S sets the request timeout in seconds.
Exit codes
| Code | Meaning | |
|---|---|---|
| 0 | Success, including truncated results | |
| 1 | The database returned an error | |
| 2 | Usage error, unknown or unsupported connection | |
| 3 | Could not connect or authenticate | |
| 4 | Refused by the environment role, or the user answered no | |
| 130 | Interrupted |
Limits
- No AI data masking applies on the CLI: you see real data, the same as
psqlwould. If the task needs masking or AI access roles, use DBCode's MCP server instead. - Passwords follow each connection's "Save password" setting. Prompts go to the terminal, never stdin. Without a terminal, a connection that needs a prompt fails with exit code 3.
Full docs: https://dbcode.io/docs/cli
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/dbcode-cli/SKILL.md
Popularity
- Repository stars
- 359
- Repository forks
- 25
- 7-day trend score
- 0
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/dbcodeio/public/dbcode-cli)