I have a problem with Python/Django
. The school
and school_application_info
tables are related. However, there is no record with some school_id
in school_application_info
. So I added null=True, blank=True
by going like this:
school = models.OneToOneField(School, related_name='school_application_info', null=True, blank=True)
Then I did the Django migrations commands:
./manage.py makemigrations
./manage.py migrate
But it is not working and generates an error:
SchoolViewSet: ErrorResponse - status:400, resp:{'school_application_info': [u'This field may not be null.']}