fix(gaussdb): support M mode SQL generation and DDL

This commit is contained in:
zipg authored and GitHub committed 2026-07-31 13:51:26 +08:00
1 parent 9057b746a6
commit 71a30e921e
12 files changed
+296 -37

No files matched your search

@@ -5223,6 +5223,7 @@ const {
copyInsertTargetLabel: computed(() => props.tableMeta?.tableName ?? props.customSaveHandler?.targetLabel),
mongoUpdateTarget: computed(() => props.mongoUpdateTarget),
databaseType: computed(() => props.databaseType),
identifierQuote: computed(() => connectionStore.connectionIdentifierQuote(props.connectionId)),
connectionId: computed(() => props.connectionId),
database: computed(() => props.executionDatabase ?? props.database),
context: computed(() => props.context),
@@ -1876,6 +1876,7 @@ async function exportTableData(row: ObjectBrowserRow, format: "csv" | "xlsx", co
connectionId: props.connection.id,
database: props.database,
schema,
identifierQuote: connectionStore.connectionIdentifierQuote(props.connection.id),
tableName: row.name,
filePath,
format,
@@ -1248,7 +1248,8 @@ async function loadTemplateContext(allowView = false) {
}
}
return { node, dbType, tableSchema, columns, tableType };
const identifierQuote = connectionStore.connectionIdentifierQuote(node.connectionId);
return { node, dbType, identifierQuote, tableSchema, columns, tableType };
}
function openSqlTemplateTab(connectionId: string, database: string, schema: string | undefined, catalog: string | undefined, sql: string, title?: string) {
@@ -1262,6 +1263,7 @@ async function newSelectTemplate() {
if (!context) return;
const sql = buildTableSelectTemplate({
databaseType: context.dbType,
identifierQuote: context.identifierQuote,
catalog: context.node.catalog,
database: context.node.database,
schema: context.tableSchema,
@@ -1280,6 +1282,7 @@ async function newInsertTemplate() {
if (!context) return;
const sql = buildTableInsertTemplate({
databaseType: context.dbType,
identifierQuote: context.identifierQuote,
catalog: context.node.catalog,
database: context.node.database,
schema: context.tableSchema,
@@ -1299,6 +1302,7 @@ async function newUpdateTemplate() {
if (!context) return;
const sql = buildTableUpdateTemplate({
databaseType: context.dbType,
identifierQuote: context.identifierQuote,
catalog: context.node.catalog,
database: context.node.database,
schema: context.tableSchema,
@@ -1317,6 +1321,7 @@ async function newDeleteTemplate() {
if (!context) return;
const sql = buildTableDeleteTemplate({
databaseType: context.dbType,
identifierQuote: context.identifierQuote,
catalog: context.node.catalog,
database: context.node.database,
schema: context.tableSchema,