feat: add "Copy as SQL ALTER" to DataGrid column header context menu
Right-click a column header in the data grid to copy the ALTER TABLE statement for that column, making it easy to replicate column definitions across databases. Supports all major dialects (MySQL, Postgres, SQL Server, Oracle, ClickHouse, SQLite, DuckDB, H2). Closes #516
This commit is contained in:
1 parent
51e62d4c60
commit
6c0db6f517
12 files changed
+246
-2
No files matched your search
@@ -352,6 +352,13 @@ pub fn build_create_table_sql(
|
||||
Ok(dbx_core::table_structure_sql::build_create_table_sql(options))
|
||||
}
|
||||
|
||||
#[tauri::command]
|
||||
pub fn build_single_column_alter_sql(
|
||||
options: dbx_core::table_structure_sql::SingleColumnAlterSqlOptions,
|
||||
) -> Result<dbx_core::table_structure_sql::TableStructureSqlResult, String> {
|
||||
Ok(dbx_core::table_structure_sql::build_single_column_alter_sql(options))
|
||||
}
|
||||
|
||||
#[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))
|
||||
|
||||
Reference in new issue
Block a user