Created
May 5, 2015 04:11
-
-
Save jean/862408a974c28502a01e to your computer and use it in GitHub Desktop.
This file contains hidden or 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
"""empty message | |
Revision ID: 1c839cbdeb51 | |
Revises: None | |
Create Date: 2015-05-05 04:08:56.274253 | |
""" | |
# revision identifiers, used by Alembic. | |
revision = '1c839cbdeb51' | |
down_revision = None | |
from alembic import op | |
import sqlalchemy as sa | |
from sqlalchemy.dialects import postgresql | |
def upgrade(): | |
### commands auto generated by Alembic - please adjust! ### | |
op.drop_table('users') | |
[...] | |
op.drop_table('domains') | |
### end Alembic commands ### | |
def downgrade(): | |
### commands auto generated by Alembic - please adjust! ### | |
op.create_table('domains', | |
sa.Column('id', sa.INTEGER(), server_default=sa.text(u"nextval('domains_id_seq'::regclass)"), nullable=False), | |
[...] | |
) | |
op.create_table('users', | |
sa.Column('id', sa.INTEGER(), nullable=False), | |
[...] | |
sa.PrimaryKeyConstraint('id', name=u'users_pkey') | |
) | |
### end Alembic commands ### |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment