HI Nomeh, Thanks for that. I have deleted the migration files, and made migrations again. Can you clarify exactly the python command:
py manage.py sqlmigrate [app_Name]0001 if my app is called products please as I am getting: (venv) C:\Users\user\PycharmProjects\JoanneShop>py manage.py sqlmigrate products0001 usage: manage.py sqlmigrate [-h] [--database DATABASE] [--backwards] [--version] [-v {0,1,2,3}] [--settings SETTINGS] [--pythonpath PYTHONPATH] [--traceback] [--no-color] app_label migration_name manage.py sqlmigrate: error: the following arguments are required: migration_name Thanks! Iain On Mon, 4 May 2020 at 19:32, Nomeh Uchenna Gabriel <nomehgabri...@gmail.com> wrote: > Hi! the reason is probably because you happened to have deleted "some but > not all of your migrations" > > ... django will always look for the latest "sqlmigrate" with the versions > in the right order(0001,0002,000x...) before it allows "makemigrations" add > a new one. > > To fix, this you must: > > delete all your migration files located at "app_Name/migrations" then run > > >>> py manage.py makemigrations [app_Name] > > > >>> py manage.py migrate [app_Name] > > ...you can skip app_Name if it's the only app in your project but I advise > you add it anyway. > > after that you can run: > >>> py manage.py sqlmigrate [app_Name]0001 > > if that shows your latest migrations, then it's done bro! your project > should work now. > > also check out your migrations and see how django added the new one. > > where app_Name === your app name (the one that you added to > 'installed_apps' of settings.py > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to django-users+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/django-users/8d1564bb-67c9-4215-8a2b-92afa3e0bcab%40googlegroups.com > . > -- Iain Stewart 2b Priestfield Road EDINBURGH EH16 5HH SCOTLAND iain.a.stew...@gmail.com telephone: 0044 131 662 9123 mobile: 0044 7728 752824 -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAAAU1KRDwxmF%2BePaUrWcLZVNNpGYz9rJ%2Bg%2BJetqgydkz%3DxGcVQ%40mail.gmail.com.