[odb-users] --suppress-migration issues
Steffen Groot
SGroot at lely.com
Fri Apr 22 10:06:11 EDT 2016
Hello all,
We're using ODB on a sqlite database. I'd like to add an
on_delete(cascade) constraint to an existing data model. This is not
possible to migrate with sqlite, so ODB gives an error when running the
pre-compiler. So, in this case i'd like to do the migration myself and run
the compiler with the --suppress-migration option. However, I still get
the error, so I'm not able to generate the new model at all. Is this a
bug?
I can work around the problem by doing it in 2 steps, but I guess the
--supress-migration option should just suppress the error?
On a slightly related note, is it possible to access the 'create table'
statement that exists in the generated code? From the source I guess not,
but it would be usefull in my custom migration script.
(Since the alter table statement is so limited in sqlite, I want to do
rename table - create new table - migrate data - remove renamed table.
Would be also be a nice feature for ODB of course ;) )
Greetings,
Steffen
More information about the odb-users
mailing list