python Manage.py syncdb does not work!

Asked

Viewed 6,375 times

1

When trying to follow a tutorial

I can’t go on because the bank wasn’t set up, you can help me?

Error:

Unknown command: 'syncdb'
Type 'manage.py help' for usage.
  • If you use the command help, as recommended, what is the output?

  • Anderson, appear several reserved words but none of them is syncdb, I found other posts that have the same command with syncdb, so I decided to post here. I imagine it might be something missing from my environment or something.

  • In the previous section, "Creating a Django project", the command is used python ../manage.py, while in that is just python manage.py. The two files exist?

  • Yes there are, the manager.py is in the first webserver directory, I tried to run python .. /Manage.py syncdb, gives the same error. I tried to get back a level in the directory, gives the same error.

  • I found the answer[http://stackoverflow.com/questions/28685931/unknown-command-syncdb-running-python-manage-py-syncdb], syncdb has been removed is to use migrate

2 answers

2


Actually, the correct command is:

./manage.py migrate --run-syncdb

or

python manage.py migrate --run-syncdb

Comando run-syncdb

  • Thanks Victor, how it worked I didn’t even bother to check the manual.

  • I’m glad I could help!

1

found the reply

syncdb command has been removed from Django, now use migrate.

python manage.py migrate

I tested it here and it worked!!!

Browser other questions tagged

You are not signed in. Login or sign up in order to post.