@oasissys/sqlcl-cli 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,43 @@
1
+ ---
2
+ name: sqlcl-cli
3
+ description: Manage Oracle SQLcl connections and run SQL against the Oasis databases from the shell — list/add/remove/switch saved connections and execute queries or DML. Use when the user asks about Oracle DB connections, running SQL/queries, checking data, or SQLcl on the Oasis databases.
4
+ ---
5
+
6
+ # oasis-sqlcl
7
+
8
+ Shell CLI over Oracle SQLcl (same `sql` binary + wallet as the SQLcl MCP). Requires Oracle SQLcl (`sql`) installed: ~/.oasis/sqlcl/bin, $SQLCL_PATH, or on PATH.
9
+ Invoke as `oasis-sqlcl` (on PATH after a global install; no install: `npx -y @oasissys/sqlcl-cli`). TOON output; exit 0/1/2; every command has `--help`.
10
+
11
+ ## Connections
12
+
13
+ Connections live in SQLcl's wallet (`~/.dbtools/connections`). The active
14
+ connection (a pointer in `~/.oasis.json`) is used by `run` unless `--conn` is given.
15
+
16
+ ## Commands
17
+
18
+ | Command | What it does |
19
+ |---|---|
20
+ | `oasis-sqlcl (no args)` | live view: saved connections + which is active |
21
+ | `oasis-sqlcl connections` | list saved connections |
22
+ | `oasis-sqlcl use <name>` | set the active connection |
23
+ | `oasis-sqlcl add <name> --host <h> --service <s> --user <u> --password <p>` | save + verify a connection |
24
+ | `oasis-sqlcl rm <name>` | remove a connection |
25
+ | `oasis-sqlcl test --host <h> --service <s> --user <u> --password <p>` | verify credentials without saving |
26
+ | `oasis-sqlcl run <SQL> [--conn <n>] [--limit <n>] [--raw]` | run SQL; results as a TOON table (--raw for DML/PLSQL output) |
27
+
28
+ ## Examples
29
+
30
+ ```sh
31
+ # See connections, pick one, query
32
+ oasis-sqlcl
33
+ oasis-sqlcl use oasisdev
34
+ oasis-sqlcl run "SELECT id, name FROM patients WHERE rownum <= 10"
35
+
36
+ # Target a specific connection, or run DML with raw feedback
37
+ oasis-sqlcl run "SELECT * FROM dual" --conn oasisqa
38
+ oasis-sqlcl run "UPDATE t SET x = 1 WHERE id = 5" --raw
39
+ ```
40
+
41
+ ## Notes
42
+ - `run`: SELECT → TOON table (50 rows, `--limit`); `--raw` for DML/DESCRIBE/PL-SQL output.
43
+ - `add`/`test` connect to verify (fail with the ORA-… error). First connection becomes active.