当前位置:Gxlcms > 数据库问题 > Mysql 8.0 ERROR 1064 (42000)

Mysql 8.0 ERROR 1064 (42000)

时间:2021-07-01 10:21:17 帮助过:4人阅读

在mysql 8.0中使用mysql5.7的语法对mysql进行远程登录授权时会报语法错误
技术图片

正确的姿势是:

  1. <code>CREATE USER ‘root‘@‘%‘ IDENTIFIED BY ‘****密码****‘;
  2. GRANT ALL ON *.* TO ‘root‘@‘%‘;
  3. ALTER USER ‘root‘@‘%‘ IDENTIFIED WITH mysql_native_password BY ‘****密码****‘;</code>

技术图片

  1. <code>mysql> use mysql;
  2. Reading table information for completion of table and column names
  3. You can turn off this feature to get a quicker startup with -A
  4. Database changed
  5. mysql> select host, user, authentication_string, plugin from user;</code>

技术图片

Mysql 8.0 ERROR 1064 (42000)

标签:str   you   startup   rom   read   string   his   lte   ima   

人气教程排行