Hi all, I'm currently working on web2py with an Oracle Database backend (Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production) but I'm having an issue with the generated Oracle command for altering a table.
I had a table definition as follows (in web2py): db.define_table('device', Field('hostname', 'string', requires=IS_NOT_EMPTY(), label=T('Hostname')), Field('device_location', 'string', label=T('Location')), ... more stuff) and updated it db.define_table('device', Field('hostname', 'string', requires=IS_NOT_EMPTY(), label=T('Hostname')), Field('device_location', 'string', label=T('Location')), Field('dashboard_category', 'reference dashboard_category', label = T('Category')), ... more stuff) so the DAL generated the following statement for altering the device table: ALTER TABLE device ADD dashboard_category NUMBER, ADD CONSTRAINT device_dashboa__constraint FOREIGN KEY (dashboard_category) REFERENCES dashboard_category (id) ON DELETE CASCADE; (whis is wrong!!!) It had to generate ALTER TABLE device ADD dashboard_category NUMBER ADD CONSTRAINT device_dashboa__constraint FOREIGN KEY (dashboard_category) REFERENCES dashboard_category (id) ON DELETE CASCADE; It added an extra comma that makes the command to fail. I now have to manually update the database with a fake_migrate help but i guess this is a bug -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.