[openstack-dev] Help with sql upgrade and downgrade

2014-08-20 Thread Murali Balcha
Hi, I am trying to add two new columns to backups table in cinder. I created the new version file as follows: from sqlalchemy import Column, MetaData, String, Table, Boolean def upgrade(migrate_engine): meta = MetaData() meta.bind = migrate_engine backups = Table('backups',

Re: [openstack-dev] Help with sql upgrade and downgrade

2014-08-20 Thread Mathieu Gagné
On 2014-08-20 6:42 PM, Murali Balcha wrote: I can successfully add string column parent_id without any problem. However adding a boolean column is vexing. Adding a boolean column adds a check constraint on the table but when I remove the column in the downgrade, the check constraint for