Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ignore creating tables, if they already exist #68

Merged
merged 1 commit into from
Nov 2, 2022

Conversation

chrispelzer
Copy link
Member

Wrap the creates with hasTable to make sure they don't exist before trying to create them, otherwise it will error if tables are created outside migrations with no way of avoiding previously

Fixes #67

@chrispelzer chrispelzer self-assigned this Nov 2, 2022
… trying to create them, otherwise it will error if tables are created outside migrations with no way of avoiding previously
@chrispelzer chrispelzer force-pushed the ignore-creating-tables-if-they-already-exist branch from 7550295 to 047cc44 Compare November 2, 2022 11:45
@chrispelzer chrispelzer merged commit aa834dc into main Nov 2, 2022
@chrispelzer chrispelzer deleted the ignore-creating-tables-if-they-already-exist branch November 2, 2022 11:52
Copy link
Member

@nickdenardis nickdenardis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@webcodecs
Copy link

I would recommend to wrap the publishing of the migrations with hasTable and not the migration himself. In this case we will get a lot of entries in the migration table.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Migrations doesnt check for exisiting table
3 participants