Scope | Databases | Grant | Description |
---|---|---|---|
Global | n/a | PROCESS | Enable the user to see all processes with SHOW PROCESSLIST. |
Global | n/a | REPLICATION SLAVE | Enable replicas to read binary log events from the source. |
Global | n/a | REPLICATION CLIENT | Enable the user to ask where source or replica servers are. |
Global | n/a | RELOAD | Enable use of FLUSH operations. |
Table | <DATABASE_NAME> , ps_import_* , _vt , mysql .func | SELECT | Enable use of SELECT. |
Table | <DATABASE_NAME> , ps_import_* , _vt | INSERT | Enable use of INSERT. |
Table | <DATABASE_NAME> | LOCK TABLES | Enable use of LOCK TABLES on tables for which you have the SELECT privilege. |
Table | <DATABASE_NAME> | SHOW VIEW | Enable use of SHOW VIEW. |
Table | <DATABASE_NAME> , ps_import_* , _vt | UPDATE | Enable use of UPDATE. |
Table | <DATABASE_NAME> , ps_import_* , _vt | DELETE | Enable use of DELETE. |
Table | ps_import_* , _vt | CREATE | Enable database and table creation. |
Table | ps_import_* , _vt | DROP | Enable databases, tables, and views to be dropped. |
Table | ps_import_* , _vt | ALTER | Enable use of ALTER TABLE. |
NoteThe descriptions in the table above were taken from the MySQL docs. For a full list of all possible grants and their
impact, please refer to the GRANT Statement page of the MySQL
docs, and locate the section titled Privileges Supported by MySQL.
Script to create user
This MySQL script can be used to create a user with the necessary permissions inside of your database. You will need appropriate database permissions to run the script. The username will bemigration_user
. Make sure to update the following variables:
<SUPER_STRONG_PASSWORD>
— The password for themigration_user
account.<DATABASE_NAME>
— The name of the database you will import into PlanetScale.