Re: SQlite migration with batch mode - help needed

2015-05-26 Thread Mike Bayer
On 5/26/15 9:47 AM, Sylvain Martel wrote: Hi, Not knowing much about SQL stuff, I used Flask-Migrate, which use alembic, to deal with migrations. But now I have to deal with a migration where I can't simply destroy the SQLite database and remake it.(which is how I dealt so far when an

Re: SQlite migration with batch mode - help needed

2015-05-26 Thread Sylvain Martel
P.S. I tried this: def upgrade(): ### commands auto generated by Alembic - please adjust! ### with op.batch_alter_table(incomes) as batch_op: batch_op.add_column(sa.Column('income_classtype', sa.Integer(), nullable=True)) batch_op.create_foreign_key(None, 'incomes',