@rex0220/kintone-sql-tools 1.2.0 → 1.4.0
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.
- package/README.md +14 -2
- package/dist-cli/ksql.js +1617 -516
- package/dist-mcp/ksql-mcp.js +1315 -243
- package/dist-mcpb/ksql-mcp.mcpb +0 -0
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -4,12 +4,16 @@ kintone アプリを SQL 風の構文で操作するツールセットです。
|
|
|
4
4
|
|
|
5
5
|
- kintone プラグイン(UI)
|
|
6
6
|
- CLI(`ksql`)
|
|
7
|
+
- MCP サーバー(AI クライアントから kintone を SQL 操作。Claude Desktop 用 MCPB 同梱)
|
|
7
8
|
|
|
8
9
|
## 機能概要
|
|
9
10
|
|
|
10
11
|
- `SELECT`(JOIN/GROUP BY/HAVING/CTE/UNION)
|
|
11
12
|
- `INSERT` / `UPDATE` / `UPSERT` / `DELETE` / `REORDER`(`--allow-dml` 必須)
|
|
12
13
|
- `EXPLAIN`
|
|
14
|
+
- **バッチ実行(`;` 区切りの複文)と一時テーブル `CREATE TEMP TABLE #t AS SELECT ...`**(v1.4.0)
|
|
15
|
+
- CLI / MCP: read-only バッチ + DML バッチ(一時テーブル経由の `INSERT ... SELECT` を含む)
|
|
16
|
+
- プラグイン: read-only バッチのみ(最終結果を表示)
|
|
13
17
|
- サブテーブル仮想テーブル(`APP100$明細`)
|
|
14
18
|
- CLI 拡張 `APP@profile`
|
|
15
19
|
- 同一 SQL 内で同一 APP の profile 混在を許可
|
|
@@ -42,16 +46,20 @@ npm run build:plugin
|
|
|
42
46
|
## 使い分け(CLI / Plugin)
|
|
43
47
|
|
|
44
48
|
- CLI を使うケース:
|
|
45
|
-
-
|
|
49
|
+
- DML を含むバッチ実行・SQL ファイル実行(`-f`)
|
|
46
50
|
- CI/CD 連携
|
|
47
51
|
- `APP@profile` を使った環境切替
|
|
48
52
|
- `--dry-run` / `EXPLAIN` による安全確認
|
|
49
53
|
|
|
50
54
|
- Plugin を使うケース:
|
|
51
|
-
- kintone
|
|
55
|
+
- kintone 画面内での対話操作(read-only バッチ + 一時テーブルも利用可)
|
|
52
56
|
- 非エンジニア向けの運用
|
|
53
57
|
- UI で結果確認したい場合
|
|
54
58
|
|
|
59
|
+
- MCP を使うケース:
|
|
60
|
+
- Claude 等の AI クライアントから kintone を照会・更新
|
|
61
|
+
- 一時テーブルで中間結果をサーバー内に保持し、AI のコンテキスト消費を抑えたい場合
|
|
62
|
+
|
|
55
63
|
注意:
|
|
56
64
|
|
|
57
65
|
- `@profile` は CLI 拡張です。plugin 側では非対応です。
|
|
@@ -113,6 +121,7 @@ Options:
|
|
|
113
121
|
--dry-run Parse and show execution plan only
|
|
114
122
|
--format <type> Output format: table | json | jsonl | csv | markdown | md
|
|
115
123
|
--max-records <n> Max records to fetch (default: 500)
|
|
124
|
+
--fetch-parallel <n> Parallel page fetches per query: 1-10 (default: 3)
|
|
116
125
|
--on-limit <mode> On record limit: error | truncate
|
|
117
126
|
--timeout <ms> Request timeout in milliseconds (default: 30000)
|
|
118
127
|
--config <path> Config file path (default: ./ksql.config.json)
|
|
@@ -145,6 +154,7 @@ Options:
|
|
|
145
154
|
--yes Skip DML confirmation prompt
|
|
146
155
|
--allow-without-where Allow UPDATE/DELETE without WHERE
|
|
147
156
|
--dml-max-rows <n> Max affected rows for DML guard (default: 100)
|
|
157
|
+
--continue-on-error Batch: keep executing after a statement error (read-only batch only)
|
|
148
158
|
-h, --help Show help
|
|
149
159
|
-v, --version Show version
|
|
150
160
|
```
|
|
@@ -182,6 +192,8 @@ Options:
|
|
|
182
192
|
- [Docs Index](docs/README.md)
|
|
183
193
|
- [言語リファレンス](docs/ksql_language_reference.md)
|
|
184
194
|
- [CLI / Console 仕様](docs/ksql_cli_console_spec.md)
|
|
195
|
+
- [バッチ実行・一時テーブル仕様](docs/ksql_batch_temp_table_spec.md)
|
|
196
|
+
- [MCP サーバー仕様](docs/ksql_mcp_server_spec.md) / [Claude Desktop への導入(MCPB)](docs/ksql_mcpb_claude_desktop_install.md)
|
|
185
197
|
- [APP@profile 仕様](docs/cli_app_profile_spec.md)
|
|
186
198
|
- [公開前チェックリスト](docs/internal/public_release_checklist.md)
|
|
187
199
|
|