-
Notifications
You must be signed in to change notification settings - Fork 82
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix previous version detection in the presence of inferred DDL migrat…
…ions (#197) Update the definition of the `previous_version` function to use a recursive CTE to find the first non-'inferred' parent of the current version. This requires adding a new column to the `pgroll.migrations` table to record whether a migration is a pgroll migration or an inferred DDL change made outside of pgroll. Together, this means that the previous version schema is removed correctly when there have been inferred DDL changes between the current and previous pgroll migration. Fixes #196
- Loading branch information
1 parent
2429a6b
commit c029d5e
Showing
2 changed files
with
105 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters