Hi folks,
I'm here again trying to up to date the django-firebird backend.
The last stable version was for django 1.8 LTS, that came to end of life, so I want to update to 1.11 LTS first and then to 2.0.
Having said that, one of unresolved things is about adding a non-nullable field to a populated table, in this case Firebird seems to work differently than others sql engines.
If I have to update data over a recently added field (actually django does this adding a default value and removing this afterward), I need commit the alter table command first then, populate the new field with the provide default value. [1]
Firebird doesn't allow updates/inserts to use objects created in the same transaction (in this case the column) because DDL is actually only really executed/completed at transaction commit.
Then, What do you think is the best approach to achieve this?
Is necessary to rewrite the context maneger interface of BaseDatabaseSchemaEditor?
Maybe a new hook to run command after the metadata update finish?
Regards.
[1] Here there's a discussion about this