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
When using --sql the current revision seems unknown #248
Comments
Michael Bayer (@zzzeek) wrote:
→ 15376ba |
Changes by Michael Bayer (@zzzeek):
|
Michael Bayer (@zzzeek) wrote:
For upgrading/downgrading in |
xealot (@xealot) wrote: Gah, sorry for the trouble. I was all over this section of the documentation and I thought I this pattern. I must have done something stupid because it does indeed work. Thanks again. |
Michael Bayer (@zzzeek) wrote: the --sql flag accepted by |
xealot (@xealot) wrote: I didn't actually need the command but I too thought it didn't make sense so I thought I would see what happened. It felt like the same error to me so I mentioned it. My use case is definitely with the update/downgrade command. |
Migrated issue, originally created by xealot (@xealot)
Running this command:
Alembic correctly starts from the revision which is set in the
alembic_version
table as expected. However after adding a--sql
flag, Alembic no longer attempts to read the version from the DB and so the output is always from the beginning of all migrations.Alternatively when I attempt to use
--autogenerate
with--sql
in some cases I get the error "Database is not up to date". I assume this is because of the same or similar reason.Am I missing something? Something that makes
--sql
behave the same as when not using--sql
.The text was updated successfully, but these errors were encountered: