Home > other >  1142, "the ALTER command denied to the user 'root
1142, "the ALTER command denied to the user 'root

Time:12-11

RT

From the remote database to such as mysql database to generate modes. The py
 
Python3 manage. Py inspectdb & gt; The login/models. Py

Modified the table below the corresponding Model name, then execute
 
Python manage. Py makemigrations login

There is no error
Then the
 
Python manage. Py migrate

An error
 
1142, "the ALTER command denied to the user 'root


Note: a remote mysql database, you can't modify the table structure, can add and delete data, the program

I wonder:
1. In theory I export data, does not modify the table structure, but why error writing cannot change the permissions,
2. The database will not be able to change the configuration, the local django can modify what is not an error,
thank you

CodePudding user response:

Modified the corresponding Model name in the table below, the changes in the Model will need to change table permissions
  • Related