After a recent migration from Oracle to Postgres and an upgrade from Django 1.2 to 1.3, we began having problems when saving objects to our database. When save() is called no id is returned, this occurs even when saving the standard django auth models through the standard django admin panel ('/admin/auth/user/None/' is returned even though the user was added to the db and had an id).
All our other sites that run off the same db do not have this problem, however they are running either Django 1.1 or 1.2.
We discovered that for new tables created post-migration their sequence had an 'owned by' attribute that was owned by the column that the sequence was on (usually the id column). Altering the 'owned by' attribute fixed the issues we were having in 1.3.
Does anybody know what the under lying cause for this is? We have found a solution if anyone else is having this issue, but we would love to know what caused it.