django - Can't add a new field in migration: "column .. does not exist" -
I want to add a field to my model but I'm completely lost here. This is the model, the app name is called "profile":
class profiles (model.model): user = model.oneoinfield (user, unique = true, null = true) alias = Model Chorphild (max _ lang = 75, null = tru) # New field description = model Model
I did this
Pyro manage.py migrate profiles --fake python manage.py migrate profile
and then when I try to work with the model, I get an error
Prog Trimming Error: Column Profile Profiles. Name does not exist
Message I get when I try to migrate:
"Migrate Nothing "and" nothing has changed "
When I try to do a schemigration, a migration: /? ¿.
The correct command will be:
Python manage .py schemamigration & LT; App_name & gt; --Ao
You have to write the name of app , not model .
Comments
Post a Comment