0👍
✅
So far the only “solution” was to trash all the migrations and re-create the database. Thus trashing all the old data. But it is less of a pain than fixing this craziness.
1👍
The Error1075 ‘Incorrect table definition’ came from Mysql, not Django. That is because the table u changed got 2 auto_created fields, while it is only one field alled allow for one table in Mysql.
In Django, just add a parm ‘auto_created’:
serial_number = models.AutoField(primary_key=True, auto_created=False)
then remove u old migrations file last time and make migrations again, continue migrate will be ok.
- Pass User obj to view trough custom authentication
- Django 1.9 Create hstore Extension Automatically w/o pre_syncdb
- Filter objects in admin
Source:stackexchange.com