Using Django, MySQL, HTML, JS, Ajax to simulate the development of blog system (2)

Then we need to execute the shell command of manage.py---click Tools->select Run manage.py

After execution, the following interface will appear

We need to enter three commands after manage.py@blog

  • 1. makemigrations BlogUser---Press Enter, this command will generate a new file named 0001_initial.py under migrations under BlogUser
  • 2. sqlmigrate BlogUser 0001--press enter, this command is used to generate sql statement
  • 3. migrate BlogUser 0001--Press Enter, this command is used to execute the generated sql statement. After the execution, it will automatically generate two tables for us in the 'tables' folder under py_blog in SQLyog

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325507334&siteId=291194637