You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've got a problem when I try to migrate an auditlogged model that isn't in the same MySQL database as the User table. It creates the table but then can't create the foreign key constraint and raises and IntegrityError
Tried with with Django 1.8 on Python 2.7 and Django 1.11 on Python 3.6, MySQL databases require the auditlogged model to be in the same database as the User table. SQLite databases don't have a problem here.
I've made a minimal example gist and hopefully I'm not missing something obvious.
I've got a problem when I try to migrate an auditlogged model that isn't in the same MySQL database as the User table. It creates the table but then can't create the foreign key constraint and raises and IntegrityError
django.db.utils.IntegrityError: (1215, 'Cannot add foreign key constraint')
Tried with with Django 1.8 on Python 2.7 and Django 1.11 on Python 3.6, MySQL databases require the auditlogged model to be in the same database as the User table. SQLite databases don't have a problem here.
I've made a minimal example gist and hopefully I'm not missing something obvious.
After downloading set up virtual env
Migration of default database
Migrate second database with auditlogged model, raises IntegrityError
The text was updated successfully, but these errors were encountered: