I dropped MySQL database used by my Django project by a mistake. Fortunately, it's only my development environment. How can I recreate the database and all the tables?
When I do python manage.py syncdb
it fails with
_mysql_exceptions.OperationalError: (1049, "Unknown database 'myproject'")
Any help will be much appreciated.
You have to create the database within MySQL before running syncdb:
mysql> create database myproject;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With