Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

django view sql behind migration

# Use the sqlmigrate command from manage.py.
python manage.py sqlmigrate <appname> <migration number eg. 0001 or 0004>
# example:
python manage.py sqlmigrage pages 0001
# output:
# CREATE TABLE... SQL 
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #django #view #sql #migration
ADD COMMENT
Topic
Name
2+2 =