django-admin.py startproject MySite
This command creates a MySite directory in the current directory.
django-admin.py this file in the C:\Python27\Lib\site-packages\django\bin folder, you can add the directory to the system path.
Django has a lightweight Web server built into it.
Enter the MySite directory, now go in there and run the python manage.py runserver command
Start the server, use Http://127.0.0.1:8000/to browse, 8000 is the default port number.
python manage.py runserver 8080
Change server port number
python manage.py Shell
Start the Interactive interface
python manage.py startapp Books
Create an app called books
python manage.py Validate
Verify that the Django Data model code has errors
python manage.py sqlall Books
Generate SQL code for the model
python manage.py syncdb
Run the SQL statement and create the corresponding table for the model
python manage.py Dbshell
command line tools to start the database
manage.py sqlall Books
View all the tables under this app
python manage.py syncdb
Synchronize the database to generate additional database tables used by the Admin interface