Reputation: 4415
I'm trying to run my first Django application with sqlite3 database. When I run python manage.py sql my_app
, it outputs the SQL queries, but the sqlite file is empty. What could be the reason?
Upvotes: 1
Views: 181
Reputation: 40193
That command just prints the sql statements. If you want to create the schema in the sqlite file, run:
python manage.py syncdb
If you are trying to export the sql statements to a text file:
python manage.py sql my_app > my_file.sql
Upvotes: 1