The reason for this error is that there is no permission to open
Solution:
1. Open the cmd command panel
2. Enter mysql -u root -p
, and then enter the password (the password of the database root account)
3. Open the authority
open all
GRANT ALL PRIVILEGES ON . TO ‘root’@‘%’ IDENTIFIED BY ‘password’ WITH GRANT OPTION;
Specify ip to open
GRANT ALL PRIVILEGES ON . TO ‘root’@‘192.168.12.1’ IDENTIFIED BY ‘password’ WITH GRANT OPTION;
4. Refresh permissions flush privileges;
5. Restart MySQL net stop mysql
,net start mysql