I am very new to django and was able to finish the tutorial on djangoproject.com without any errors. I am now going through the Django REST framework tutorial found at http:
If your issue is like mine, then this a workaround. The good news is that you wont have to delete your db.
Check that there isn't some other model that uses this model as a reference.
django.db.utils.OperationalError: no such column: parts_part_type.blah
This was only happening to me because I had another model called "product" in a different app called "products" that referenced this model.
part = models.ForeignKey("parts.Part", related_name="some part", limit_choices_to={'part_type':Part_Type.objects.get(prefix='PART')},)
My solution was:
python manage.py makemigrations; python manage.py migratepython manage.py makemigrations; python manage.py migrateTechnically I think I need to change the limit_choices_to reference so