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。
TypeScript aicliclickhousedatabasedatabase-clientdatabase-managementdockerguimcpmongodbmysqlpostgresqlredisrustsql-serversqlitetaurivue
fix(mysql): retry unsupported prepared statements
t8y2dcc3e723a7c2
diff --git a/crates/dbx-core/src/db/mysql.rs b/crates/dbx-core/src/db/mysql.rsindex c39c73ce2f..92cf333886 100644--- a/crates/dbx-core/src/db/mysql.rs+++ b/crates/dbx-core/src/db/mysql.rs@@ -522,6 +522,7 @@ fn mysql_error_should_retry_without_ssl(error: &str) -> bool {fn mysql_error_should_retry_with_text_protocol(error: &str) -> bool {let lower = error.to_ascii_lowercase();(lower.contains("1105") && lower.contains("hy000"))+ || lower.contains("com_stmt_prepare")|| lower.contains("prepared statement protocol")|| lower.contains("this command is not supported in the prepared statement protocol yet")}@@ -1314,6 +1315,13 @@ mod tests {assert!(mysql_error_should_retry_with_text_protocol(error));}+ #[test]+ fn mysql_unsupported_prepare_command_can_retry_with_text_protocol() {+ let error = "ERROR PX000 (3000): [a2jupsonbbv6zai1gomo5whu36ndqy] Unsupported command: COM_STMT_PREPARE";++ assert!(mysql_error_should_retry_with_text_protocol(error));+ }+#[test]fn mysql_setup_queries_select_requested_database_before_session_init() {let queries = mysql_setup_queries("mysql://root:secret@localhost:3306/app?charset=utf8mb4");