We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I want to use migrate in my tests setup.
I have following code:
driver, err := postgres.WithInstance(db, &postgres.Config{}) if err != nil { return err } sqltest.WaitForDB(db) m, err := migrate.NewWithDatabaseInstance( "file://"+path, dbName, driver) if err != nil { return errors.Wrap(err, "cannot do migration") } err = m.Up() return err
The problem is when I apply m.Up() I get error -no change. How I can check if migration is feasible and then not apply migration?
m.Up()
no change
The text was updated successfully, but these errors were encountered:
You can check if the returned error is ErrNoChange. For more info, see: #100 (comment)
ErrNoChange
It's hard to find the duplicate issue for this, but updating this PR should help prevent duplicates from being filed in the future.
Sorry, something went wrong.
Ok, thanks for info, I'll handle it in the same way.
No branches or pull requests
I want to use migrate in my tests setup.
I have following code:
The problem is when I apply
m.Up()
I get error -no change
. How I can check if migration is feasible and then not apply migration?The text was updated successfully, but these errors were encountered: