diff --git a/packages/nocodb/src/db/BaseModelSqlv2.ts b/packages/nocodb/src/db/BaseModelSqlv2.ts index e283aff1c4..0b7c6e7bab 100644 --- a/packages/nocodb/src/db/BaseModelSqlv2.ts +++ b/packages/nocodb/src/db/BaseModelSqlv2.ts @@ -5699,7 +5699,7 @@ class BaseModelSqlv2 { trx?: any; } = {}, ) { - const transaction = trx ?? (await this.dbDriver.transaction()); + let transaction; try { const columns = await this.model.getColumns(this.context); @@ -5710,6 +5710,8 @@ class BaseModelSqlv2 { } } + transaction = trx ?? (await this.dbDriver.transaction()); + const updateDatas = raw ? datas : await Promise.all(