Skip to content

armgit / dbx

Public Imported from GitHub
0

25 MB lightweight cross-platform database client for 100+ databases, including MySQL, PostgreSQL, SQLite, Redis, MongoDB, DuckDB, SQL Server, and Dameng. Built-in AI, MCP Server, CLI, desktop and Docker. | 轻量级跨平台数据库管理工具,支持 MySQL、PostgreSQL、SQLite、Redis、MongoDB、达梦等 100+ 数据库,提供桌面端、Docker、CLI、内置 AI 助手和 MCP。

fix(frontend): restore CI compatibility checks

zipg58633bf68247
diff --git a/apps/desktop/src/lib/sql/sqlAnalysis.ts b/apps/desktop/src/lib/sql/sqlAnalysis.ts
index 5ef884aeaa..b8b30b6bfa 100644
--- a/apps/desktop/src/lib/sql/sqlAnalysis.ts
+++ b/apps/desktop/src/lib/sql/sqlAnalysis.ts
@@ -323,7 +323,8 @@ function looksLikeComputedExpression(expression: string): boolean {
const identifier = parseQualifiedIdentifier(trimmed);
if (identifier?.end === trimmed.length) return false;
if (/[+\-*/%=<>!|&^,.:]$/u.test(trimmed)) return false;
- const finalWord = trimmed.split(/\s+/u).at(-1)?.toUpperCase() ?? "";
+ const words = trimmed.split(/\s+/u);
+ const finalWord = words[words.length - 1]?.toUpperCase() ?? "";
if (new Set(["AND", "OR", "XOR", "NOT", "LIKE", "ILIKE", "IS", "IN", "BETWEEN", "WHEN", "THEN", "ELSE", "AS", "COLLATE", "AT", "DIV", "MOD", "REGEXP", "RLIKE"]).has(finalWord)) return false;
const source = parseQualifiedIdentifier(trimmed);