mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-24 07:15:58 +00:00
fix: correctly processing script outside of transactions for firebird
This commit is contained in:
@@ -114,7 +114,11 @@ const driver = {
|
|||||||
|
|
||||||
async script(dbhan, sql, { useTransaction } = {}) {
|
async script(dbhan, sql, { useTransaction } = {}) {
|
||||||
if (useTransaction) return this.runSqlInTransaction(dbhan, sql);
|
if (useTransaction) return this.runSqlInTransaction(dbhan, sql);
|
||||||
return this.query(dbhan, sql);
|
|
||||||
|
const sqlItems = splitQuery(sql, driver.sqlSplitterOptions);
|
||||||
|
for (const sqlItem of sqlItems) {
|
||||||
|
await this.query(dbhan, sqlItem, { discardResult: true });
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
async readQuery(dbhan, sql, structure) {
|
async readQuery(dbhan, sql, structure) {
|
||||||
|
|||||||
Reference in New Issue
Block a user