3👍
✅
It`s because initial migration will create all tables in database for you. And you have an existing database with existing tables. You can either wipe you database and then do a migrate or you need to use a –fake option in migrate. Docs here
python manage.py migrate DrHub --fake
- [Django]-Django.db.utils.IntegrityError: The row in table 'main_page_projects' with primary key '1' has an invalid foreign key
- [Django]-Django restrict pages to certain users
- [Django]-Parsing dates with django utils parse_date
Source:stackexchange.com