Home  >  Q&A  >  body text

Django. After migrating mysql table, manage.py does not work

I installed mysql as the database in the django project.

I did makemigration and migrated it to django.

Afterwards I wanted to try running the server, but even though I have python stored in my computer, python's manage.py doesn't work at all. python_version_in_cmd

I have a screenshot here and it doesn't show any response at all, but pip is responding. Django

This is my computer environment pathComputer environment path

mysql/python fails when I install mysql, is this the problem? Any tips?

P粉764785924P粉764785924258 days ago468

reply all(1)I'll reply

  • P粉966335669

    P粉9663356692024-02-05 00:35:00

    What error occurs when running python manage.py runserver? Without knowing this, I can make some guesses.

    1. Make sure your model is set up correctly.
    2. After writing the model, you can run python manage.py makemigrations
    3. You then need to run python manage.py migrate to apply the model to the database.

    Some guidance can be found here: https://www.geeksforgeeks.org/django-migrate-python/

    reply
    0
  • Cancelreply