feat(query): move SQL editability analysis to Rust

This commit is contained in:
t8y2 committed 2026-05-22 15:09:31 +08:00
1 parent c736fe372a
commit cb3e1d6e9f
12 files changed
+685 -7

No files matched your search

+5
View File
@@ -154,3 +154,8 @@ pub async fn analyze_sql_references(
) -> Result<dbx_core::sql_analysis::SqlReferenceAnalysis, String> {
dbx_core::sql_analysis::analyze_sql_references(&sql, dialect.as_deref())
}
#[tauri::command]
pub fn analyze_editable_query_editability(sql: String) -> Result<dbx_core::sql_editability::QueryEditability, String> {
Ok(dbx_core::sql_editability::analyze_editable_query_editability(&sql))
}
+1
View File
@@ -288,6 +288,7 @@ pub fn run() {
commands::query::execute_script,
commands::query::execute_in_transaction,
commands::query::analyze_sql_references,
commands::query::analyze_editable_query_editability,
commands::sql_file::preview_sql_file,
commands::sql_file::execute_sql_file,
commands::sql_file::cancel_sql_file_execution,