【ERROR 1064 (42000)】MySQL中使用mysqladmin或set修改root密码时提示语法错误
报错信息:
mysql> mysqladmin -uroot -p123456 password 654321;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'mysqladmin -uroot -p123456 password 654321' at line 1
mysql> set password for root@localhost = password('654321');
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'password('654321')' at line 1
报错原因:
新版本MySQL(8.0以上)不支持使用mysqladmin -uroot -p123456 password 654321;或“set password for root@localhost = password('654321');”来修改密码。
解决方法:
alter user'root'@'localhost' identified by '新密码';- 或
alter user'root'@'localhost' identified with mysql_native_password by '新密码';
【ERROR 1064 (42000)】MySQL中使用mysqladmin或set修改root密码时提示语法错误的更多相关文章
- MySQL 修改 root 密码命令
安装好 MySQL 并成功启动 MySQL 服务后,可以通过以下方法修改root密码: ①用 mysqladmin.exe 操作.指令如下: cd C:\Program Files\MySQL Ser ...
- mysql ERROR 1064 (42000): Erreur de syntaxe près de 'order)
mysql> INSERT INTO page (author_username, page_title, addtime, cat_id, page_content,author_uid,it ...
- MySQL保留字 ERROR 1064 (42000)
在MySQL(5.7.18)数据库中建表 CREATE TABLE SA_ACT_ITEM ( ITEMID ) NOT NULL, REGION ), ACTIONID ), ITEMNAME ), ...
- MySQL Workbench导出Model提示['ERROR 1064 (42000): You have an error in your SQL syntax....syntax to use near 'VISIBLE']
CREATE TABLE IF NOT EXISTS `pihealth`.`warning_events` ( `wid` INT NOT NULL AUTO_INCREMENT, `wtime` ...
- mysql 报错ERROR 1064 (42000),原因使用了mysql保留字 (right syntax to use near 'groups)
msql 8.0 执行语句: SELECT * FROM groups; 会报如题的错误, 需加反引号进行修改: SELECT * FROM `groups`; //////////分割线//// ...
- 【Mac系统】之Mysql数据库遇到修改数字密码的问题(SQL语法错误:ERROR 1064 (42000),密码策略等问题:ERROR 1819 (HY000))
安装完Mysql也进行了第一次初始化密码以及修改密码规则(请参考文章),但是我想后续再改密码,出现了下面几个问题: #SQL语句错误问题 ERROR 1064 (42000): You have an ...
- ERROR 1064 (42000): You have an error in your SQL syntax;
出现: ERROR 1064 (42000): You have an error in your SQL syntax; 1.SQL语句拼写错误. 具体很简单.慢慢查看 2.使用到了SQL关键字. ...
- mysql修改root密码和设置权限
整理了以下四种在MySQL中修改root密码的方法,可能对大家有所帮助! 方法1: 用SET PASSWORD命令 mysql -u root mysql> SET PASSWORD FOR ' ...
- 数据库之mac上mysql root密码忘记或权限错误的解决办法
[转自 http://blog.csdn.net/u014410695/article/details/50630233] 以下方法亲测有效,过程使用的工具只有mac的终端无需workbench 当 ...
随机推荐
- nginx负载均衡如何实现
什么是nginx?Nginx("engine x")是一款是由俄罗斯的程序设计师Igor Sysoev所开发高性能的Web和反向代理服务器,也是一个 IMAP/POP3/SMTP ...
- JavaScript函数创建方式
1.工厂模式 function createPerson(name, job) { var o = new Object() o.name = name o.job = job o.sayName = ...
- The Mean of the Sample Mean|Standard Deviation of the Sample Mean|SE
7.2 The Mean and Standard Deviation of the Sample Mean Recall that the mean of a variable is denote ...
- resume|issue|transmit|sake|obliged|beyond her wildest dreams|echo|transmission|immense|consistent |convey to| boasted|satisfaction|rub|enrol|demonize
If an activity resumes, or if you resume it, it startsagain after a pause. (中断后)继续,重新开始 Normal servi ...
- MyBatis XML 配置文件 properties 元素扩展
在分析 MyBatis XML 配置文件 properties 元素时提到了三种配置方式,其中 property 子元素 和 properties 文件都比较容易理解,但是为什么还要提供一种代码参数传 ...
- requests库入门-16-Session和Cookie
分类专栏: Python接口自动化测试之requests库入门 作者 | Anthony_tester ,300w+访问量博主,Oracle测试开发工程师. 地址 | https://blog.csd ...
- [Golang]字符串拼接方式的性能分析
本文100%由本人(Haoxiang Ma)原创,如需转载请注明出处. 本文写于2019/02/16,基于Go 1.11.至于其他版本的Go SDK,如有出入请自行查阅其他资料. Overview 写 ...
- Neural Turing Machine - 神经图灵机
Neural Turing Machine - 神经图灵机 论文原文地址: http://arxiv.org/pdf/1410.5401.pdf 一般的神经网络不具有记忆功能,输出的结果只基于当前的输 ...
- 一行python代码搞定文件分享
给同事分享文件,如你所知通过聊天工具,网盘或linux命令各种方法,还有一个也可以尝试下:使用一行python代码快速搭建一个http服务器在局域网内进行下载. python3使用: python3 ...
- [Statistics] Comparison of Three Correlation Coefficient: Pearson, Kendall, Spearman
There are three popular metrics to measure the correlation between two random variables: Pearson's c ...