fix: process blob values, update firebird dialect

This commit is contained in:
Pavel
2025-06-05 15:15:31 +02:00
parent dd90851477
commit e4cc4b6f58
3 changed files with 51 additions and 7 deletions

View File

@@ -4,6 +4,7 @@ const stream = require('stream');
const driverBase = require('../frontend/driver');
const Analyser = require('./Analyser');
const Firebird = require('node-firebird');
const { normalizeRow } = require('./helpers');
const { getLogger, extractErrorLogData, createBulkInsertStreamBase } = require('dbgate-tools');
const sql = require('./sql');
@@ -62,7 +63,7 @@ const driver = {
const columns = res?.[0] ? Object.keys(res[0]).map(i => ({ columnName: i })) : [];
return {
rows: res ?? [],
rows: res ? await Promise.all(res.map(normalizeRow)) : [],
columns,
};
},
@@ -108,10 +109,6 @@ const driver = {
}
},
async writeTable(dbhan, name, options) {
return createBulkInsertStreamBase(this, stream, dbhan, name, options);
},
async script(dbhan, sql, { useTransaction } = {}) {
if (useTransaction) return this.runSqlInTransaction(dbhan, sql);