[web2py] Re: Database question, problem adding column

2017-02-07 Thread martin
I'm pretty sure I tried that as well without success... However, the problem is solved now. Something was wrong with the databases files (or I was missing something) and also I had comiled files that was recreating this field whenever I tried to remove it. My solution was perhaps not so pretty

[web2py] Re: Database question, problem adding column

2017-02-07 Thread Leonel Câmara
Using the old version without the column you need both migrate=True and fake_migrate=True to rebuild the table files. Then add the new field and fake_migrate=False. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) -

[web2py] Re: Database question, problem adding column

2017-02-07 Thread martin
Thanks for your reply! I did as you said and reverted back to a version without the new field, turned fake_migrate_all on like : "db = DAL(myconf.get('db.uri'), pool_size = myconf.get('db.pool_size'), #migrate_enabled = myconf.get('db.migrate'),

[web2py] Re: Database question, problem adding column

2017-02-07 Thread Jim S
Also, I'm assuming you've also read through this: http://web2py.com/books/default/chapter/29/06/the-database-abstraction-layer?search=migrate#Other-DAL-constructor-parameters -Jim On Tuesday, February 7, 2017 at 9:14:54 AM UTC-6, Jim S wrote: > > Can you show the migrate options you've tried? >

[web2py] Re: Database question, problem adding column

2017-02-07 Thread Jim S
Can you show the migrate options you've tried? I do this all the time with MySQL and it works great. Another possibility is that it ran through migration already on a different instance of the database. If so, turn on fake_migrate_all and remove the column. That should remove it from the