django-registration (1048, “Column 'last_login' cannot be null”)
Posted 天道酬勤
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了django-registration (1048, “Column 'last_login' cannot be null”)相关的知识,希望对你有一定的参考价值。
Go to your database (mysql Terminal):
$ mysql
mysql> SELECT * FROM django_migrations;
If you see some records, good. Delete them.
mysql> TRUNCATE TABLE django_migrations;
Leave MySQL terminal, and run the migrations again in django:
$ python manage.py migrate --fake-initial
Make sure this message appears:
0005_alter_user_last_login_null - [OK]
then you might see some other conflicts, that is fine because we only need to make this migration.
Restart your MySQL and Server and you‘re good to go.
以上是关于django-registration (1048, “Column 'last_login' cannot be null”)的主要内容,如果未能解决你的问题,请参考以下文章
django-registration 与 paypal 集成