Commit Graph

1104 Commits

Author SHA1 Message Date
gggaiitx 73bd133886
fix(sqlserver): strip display width from float type in DDL generation
* fix(sqlserver): strip scale from float type while preserving mantissa bits

* fix: add missing agent_java_options field in test ConnectionConfig
2026-07-08 15:31:49 +08:00
gggaiitx 651c7b8db3
fix(vastbase): tolerate metadata row type mismatches 2026-07-08 14:57:14 +08:00
zipg 3a35f5b911
fix(oceanbase): update default connection port 2026-07-08 13:31:45 +08:00
t8y2 2929b1c035 feat(hive): add Kerberos connection options 2026-07-08 13:23:21 +08:00
t8y2 15d4dc6e2e fix(sqlserver): omit display width for integer types 2026-07-08 11:05:45 +08:00
t8y2 35710e7766 fix(postgres): handle column metadata type mismatches 2026-07-08 10:52:48 +08:00
t8y2 bb959697d0 feat(release): bump app to 0.5.50 2026-07-08 10:02:45 +08:00
t8y2 1830d76a67 fix(sqlserver): narrow named instance test 2026-07-08 09:57:12 +08:00
t8y2 0747134dc2 fix(sqlserver): preserve legacy encryption fallback 2026-07-08 09:21:21 +08:00
t8y2 6e05c5182b feat(release): bump app to 0.5.49 2026-07-08 01:16:44 +08:00
Guoyu Su 016821122c
fix(sqlite): open SQLCipher databases with configured key (#2807) 2026-07-08 00:13:25 +08:00
onenewcode ba81fa4497
feat(redis): support multiple value formats in viewer (#2766)
* feat(redis): improve value decoding and viewer formats

* fix(redis): preserve stream field/value blobs

* Revert "fix(redis): preserve stream field/value blobs"

This reverts commit 168af0619a438dbba5cf17b3e0ec9202a3100d83.
2026-07-08 00:13:20 +08:00
t8y2 ad9841ab77 fix(import): allow selecting create-table column types 2026-07-08 00:02:47 +08:00
t8y2 8364f468a0 fix(sqlserver): use legacy encryption for fallback 2026-07-07 22:51:04 +08:00
zipg 6cba08fccb
fix(kingbase): 修复连接与元数据查询异常 2026-07-07 22:12:36 +08:00
gggaiitx b49638ff1e
fix(mysql): set group_concat_max_len during setup 2026-07-07 17:58:07 +08:00
Guoyu Su c5eed06b93
fix(postgres): load foreign key referential actions 2026-07-07 17:18:02 +08:00
二丫讲梵 326c4f5495
feat(dataGrid): 增加复制逐行插入语句的功能 2026-07-07 16:39:38 +08:00
zipg d50f1761d6
fix(sql): handle database drag and routine export 2026-07-07 15:54:48 +08:00
t8y2 23d268450c fix(mysql): strip IPv6 brackets before TCP connect 2026-07-07 15:48:35 +08:00
zipg d90847bbba
feat(ai): support SQL library file references 2026-07-07 15:39:10 +08:00
LRcoding fc01cea80f
fix(oracle): preserve plsql block terminators 2026-07-07 15:29:43 +08:00
t8y2 ef39c2bfe8 fix(ssh): include SHA-1 ETM MAC fallback 2026-07-07 14:55:03 +08:00
jischeng c3893bf314
feat(spark): add Apache Spark database driver with catalog support
* feat(spark): add Apache Spark database driver

Spark Thrift Server speaks the HiveServer2 protocol, so the Spark driver
reuses the hive-jdbc agent runtime. Registers spark (agentKey=spark,
defaultPort=10015) across the manifest, DatabaseType enum, agent catalog,
SQL dialects, connection dialog, and a SparkAgent built on AbstractJdbcAgent.

* feat(spark): add catalog support and official logo

SparkAgent now supports Spark 3.4+ multi-catalog (Paimon, Lance, Iceberg)
via catalog=<name> in url_params, mirroring the StarRocks catalog flow:
- afterConnect switches to the configured catalog via USE <catalog>
- listDatabases returns the catalog name when SHOW DATABASES is empty
  (catalogs like Lance expose tables at the catalog root with no databases)
- listTables uses SHOW TABLES IN <catalog>[.<schema>] uniformly, working
  for both catalog-root tables (Lance) and catalog.schema tables (Paimon)
- setSchemaSQL qualifies USE with the catalog to prevent resetting to
  spark_catalog on schema switches
- buildJdbcUrl omits database from the URL path

Also replaces the placeholder lightning icon with the official Apache Spark
logo (spark-logo.png from spark.apache.org).

* fix(spark): use catalog-qualified DESCRIBE for column retrieval

getColumnsFromDescribe used USE <schema> + DESCRIBE <table>, which
generated USE `catalog`.`catalog` when the sidebar passed the catalog
name as the schema (Lance case where the catalog is the only node).
This failed and fell back to JDBC metadata which also returned nothing,
resulting in an empty DDL (CREATE TABLE ... ()).

Now uses DESCRIBE `catalog`.`table` directly when a catalog is
configured, bypassing USE entirely. Also fixes setSchemaSQL to treat
schema == catalog as catalog-only (no .schema suffix).

* fix(ci): add spark to metadata coverage matrix and BRIDGE_REQUIRED_TYPES

- agents/metadata-constraint-coverage.tsv: register spark as
  intentional-fallback (SHOW TABLES/SHOW DATABASES, like Hive/TDengine)
- packages/node-core/src/diagnostics.ts: add spark to
  BRIDGE_REQUIRED_TYPES (mcpMode=bridge, matches manifest)

* fix(ci): add spark to DBX_CONNECTION_TYPE_DESCRIPTION in mcp-server

The driver-manifest test asserts every manifest dbType appears in the
MCP server's connection type description string.
2026-07-07 14:36:22 +08:00
t8y2 adb8da3ad3 fix(ssh): support legacy hmac-sha1 MAC 2026-07-07 14:14:09 +08:00
t8y2 2b4cefc987 fix(gaussdb): classify stored procedures 2026-07-07 13:58:33 +08:00
t8y2 fc72be7dc2 fix(elasticsearch): resolve SQL table aliases 2026-07-07 13:37:24 +08:00
zipg 24ac0f7413
fix(sqlserver): order top query pages by exposed column
Co-authored-by: zipg <4047349+zipg@users.noreply.github.com>
2026-07-07 13:31:15 +08:00
t8y2 6e7f0578b6 fix(saphana): keep DO blocks together 2026-07-07 13:23:53 +08:00
t8y2 3161efe95f fix(postgres): skip cert parsing for non-verifying TLS 2026-07-07 13:02:35 +08:00
t8y2 ab186c30a5 fix(export): preserve PostgreSQL JSON escapes 2026-07-07 12:49:14 +08:00
t8y2 1db11ea145 feat(postgres): support batch table cascade actions 2026-07-07 11:57:44 +08:00
t8y2 df1f53acb8 feat(sqlite): support WSL UNC network paths 2026-07-07 10:41:12 +08:00
t8y2 780470384a feat(release): bump app to 0.5.48 2026-07-06 18:29:36 +00:00
t8y2 7155992e04 feat(import): create table during data import 2026-07-07 02:01:02 +08:00
zipg 668919a7c9
fix(gbase8s): make view source saves safer 2026-07-07 01:50:53 +08:00
t8y2 3609641fc8 fix(mysql): stream query result exports 2026-07-07 00:50:14 +08:00
t8y2 9cbe857a2a feat(update): 应用内更新提示支持英文 release notes 2026-07-07 00:26:56 +08:00
二丫讲梵 18e5df6f5e
feat(query-editor): enhance current statement framing 2026-07-06 23:09:21 +08:00
hhzorg 4024dc6a67
fix(milvus): send empty JSON body to databases/list endpoint
Follow-up to #2698. The databases/list call posted with no request body,
which the Milvus demo cluster used during testing accepts. Production
Milvus is stricter: a bodyless POST returns HTTP 200 with
`{"code":1801,...}` and omits the `data` field. Since the success check
only inspects the HTTP status, list_milvus_databases() parsed zero names
and silently fell back to `["default"]`, hiding every non-default database
in the sidebar.

Send an empty JSON object `{}` as the body, matching every other Milvus
v2 endpoint. With the body, the endpoint returns code 0 and the full
database list on both demo and production clusters.

Ref #2693

Co-authored-by: 朱豪豪 <zhu.hh.sz@belle.com.cn>
2026-07-06 22:04:19 +08:00
t8y2 48aa5fa2e2 fix(transfer): use Oracle INSERT ALL for batch inserts 2026-07-06 19:26:46 +08:00
hhzorg 95b7b8b9a3
fix(milvus): list all databases and their collections in sidebar
Milvus supports multiple databases, but the sidebar only ever showed
collections under the hardcoded "default" database. The backend returned
["default"] for every vector store and the frontend loaded collections
for a single database and flattened them under the connection node.

- Backend (vector_driver): add list_databases() that calls Milvus
  /v2/vectordb/databases/list (falling back to "default" for older Milvus
  and for non-Milvus vector stores), and thread a database parameter
  through find_documents() instead of hardcoding "default".
- document_ops: list_databases_core delegates VectorDb to list_databases();
  find_documents_core forwards the selected database.
- Frontend: add a "vector-database" tree node type. For Milvus, connections
  expand into database nodes, which expand into their own collections.
  Collection node ids are namespaced by database to avoid collisions
  across databases, and the collection id is stored in meta so activation
  no longer parses the node id.

Fixes #2693

Co-authored-by: 朱豪豪 <zhu.hh.sz@belle.com.cn>
2026-07-06 19:24:55 +08:00
t8y2 b6b510d632 feat(sql): support MySQL routine blocks 2026-07-06 19:06:34 +08:00
Hiep Le 78019c44e2
fix(mongo): support ISODate() and new Date() in MongoDB queries
* fix(mongo): hỗ trợ ISODate() và new Date() trong query MongoDB

Parser shell MongoDB ở frontend chỉ chuyển ObjectId(...) sang extended JSON,
nên filter chứa ISODate("...")/new Date("...") không parse được: câu lệnh rơi
xuống SQL executor và báo lỗi "Use MongoDB-specific commands".

Bổ sung rewrite ISODate(x)/new Date(x) -> {"$date":x} trong normalizeJsonArgument,
khớp với json_value_to_bson của backend (đã hiểu $date/$oid). Thêm test cho
filter dùng ISODate và new Date.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* fix(mongo): decode $date extended JSON trong filter query

json_filter_value_to_bson chỉ chuyển {"$oid":...} nên filter chứa {"$date":...}
bị gửi thẳng lên server: { field: {"$date":...} } lỗi "unknown operator: $date",
còn { field: {"$gte": {"$date":...}} } so sánh với sub-document nên không khớp gì
(trả về rỗng).

Thêm nhánh parse_extended_json_date vào json_filter_value_to_bson, đồng bộ với
json_value_to_bson (vốn đã hiểu $date/$oid). Thêm test cho cả equality và $gte.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-06 18:21:15 +08:00
t8y2 90bdacfd12 fix(grid): support multiline bulk edit values 2026-07-06 17:18:38 +08:00
LSD fa5e55a376
feat(mongodb): improve GridFS manager filtering and sorting
* docs: add GridFS manager filter and sort design

* feat: improve GridFS manager filtering and sorting
2026-07-06 17:17:33 +08:00
zipg f2c429afd9
fix: support metadata comment search
Co-authored-by: zipg <4047349+zipg@users.noreply.github.com>
2026-07-06 16:49:28 +08:00
t8y2 745f7f60b0 feat(postgres): add cascade table drop option 2026-07-06 15:45:47 +08:00
Abeautifulsnow 8539011f25
feat(ai): split Ask/Agent action menus with task-oriented Agent actions
* feat(ai): add task-oriented Agent actions with per-action contract

Introduce three Agent-native actions — query, exploreSchema,
executeAndExplain — so Agent mode surfaces task-oriented operations
instead of reusing Ask's SQL-producing action set.

- ai.ts: extend AiAction with the new actions; add ASK_ACTIONS /
  AGENT_ACTIONS and defaultActionForMode / isValidActionForMode
  helpers; raise maxTokens for the explanatory task actions.
- aiSkills.ts: add skill definitions (zh/en) for the three actions.
- aiAgentPlan.ts: task actions no longer emit a misleading
  "unsupported_action" execute step; they execute via the
  execute_query tool events, not the legacy client-side path.
- agent_loop.rs: per-action task-contract rules in both the prompt
  augmentation and repair paths (query -> execute & answer from real
  data; exploreSchema -> list_tables/get_columns; executeAndExplain
  -> run current SQL & explain).
- i18n (en/zh-CN/zh-TW): new action labels, placeholders, a
  generateNoExec label for Agent mode, and a task-oriented agent
  modeHint.

es/it/ja/pt-BR have no `ai` section and fall back to `en`, matching
existing coverage.

* feat(ai): split Ask/Agent action menus with mode-aware defaults

Wire the new Agent task actions into the assistant UI so each mode
shows a distinct, intent-matching action set.

- actionButtons is now a computed returning Ask or Agent buttons
  based on assistantMode. Agent menu: query / exploreSchema /
  executeAndExplain / generate (labeled "生成但不执行" via
  generateNoExec). Ask menu is unchanged.
- Switching mode lands on that mode's default (Ask -> generate,
  Agent -> query); the shared `generate` is not carried across
  because its label/semantics differ per mode. Vector DBs stay on
  `generate` since their action menu is hidden and they lack SQL
  tools (no execute_query contract).
- External Ask-style triggers (Fix with AI, Explain history) switch
  to Ask mode when invoked from Agent mode so the action is valid
  and the menu reflects what runs.
- Reset the active action to the mode default after each send.

* test(ai): cover Agent task-action contract and mode/action mapping

Lock in the deterministic parts of the Ask/Agent split so only the
LLM-behavior criteria need manual verification.

Backend (agent_loop.rs):
- query contract instructs the LLM to call execute_query and is not
  treated as a SQL-producing action.
- exploreSchema contract points to list_tables/get_columns and says
  not to execute data queries.
- executeAndExplain contract tells the LLM to run the current SQL.
- task actions do not require a SQL deliverable (a conclusion without
  a fenced SQL block still satisfies the contract).
- query repair prompt also targets execute_query.

Frontend (aiActions.spec.ts):
- defaultActionForMode: Ask -> generate, Agent -> query (not generate).
- isValidActionForMode: generate valid in both; Ask-only actions
  rejected in Agent mode and vice versa.
- ASK_ACTIONS / AGENT_ACTIONS composition (Agent menu starts with
  query and still offers generate).

* fix(ai): correct action menu on mode-switched triggers and i18n gaps

Issues found during review of the Ask/Agent action split:

- [#I01] triggerAction (Fix with AI / Explain history) invoked from
  Agent mode switched to Ask and set the action, but the mode-switch
  watch then reset activeAction to the Ask default ("generate"),
  overwriting the action just set — so the menu showed "Generate SQL"
  during a fix. Add a suppressModeActionReset flag so programmatic
  mode switches don't clobber the explicitly-set action.
- [#C01] Remove dead `unsupported_action` reason: buildAiAgentPlan no
  longer produces it, so drop the type variant and the unreachable
  skippedTitleKey case.
- [#I02] es/it/ja/pt-BR were missing the new Agent action keys
  (query/exploreSchema/executeAndExplain/generateNoExec) and their
  placeholders, causing English fallback in the Agent menu. Add the
  translations to match each locale's existing style.

* test(ai): align app-tests with task-action split

- aiSkills: add query/exploreSchema/executeAndExplain to the expected
  action set; broaden the id check (new ids are not _sql-suffixed) and
  relax the userInstruction assertion (schema inspection need not mention SQL).
- aiAgentPlan: drop the unsupported_action skipped step for non-generate
  actions (#C01 removed it from the plan and the reason union); add coverage
  for task-oriented Agent actions not driving client-side execution.

* test(ai): pin locale in dialect prompt spec

buildSystemPrompt selects zh/en copy via currentLocale(), which reflects the
host navigator.language. The spec asserts English strings, so it failed on
zh-CN machines (e.g. Windows with a Chinese system locale) while passing on
CI's en-US runners. Pin the locale to en in beforeAll so the assertions are
deterministic regardless of the host OS locale.
2026-07-06 14:41:39 +08:00
t8y2 e84fb12fcc feat(sqlite): support SQLCipher encrypted databases 2026-07-06 14:24:28 +08:00