Skip to content

Commit d98b472

Browse files
Update src/migration/migrator.ts
Co-authored-by: Igal Klebanov <igalklebanov@gmail.com>
1 parent 65e1d74 commit d98b472

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/migration/migrator.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -527,6 +527,10 @@ export class Migrator {
527527
}
528528

529529
if (this.#props.db.isTransaction) {
530+
if (!adapter.supportsTransactionalDdl) {
531+
throw new Error('Transactional DDL is not supported in this dialect. Passing a transaction to this migrator would result in failure or unexpected behavior.')
532+
}
533+
530534
return run(this.#props.db)
531535
} else if (
532536
adapter.supportsTransactionalDdl &&

0 commit comments

Comments
 (0)