
mysql
hanyren
这个作者很懒,什么都没留下…
展开
-
mysql数据库忘记密码
关闭mysql服务,启动mysql无密码模式:mysqld --skip-grant-tables use mysql; select user,host,password from user; 更改root密码,输入update user set password=password('admin123') where user='root' and host='localhost';...原创 2020-02-17 17:25:21 · 153 阅读 · 0 评论 -
mysql命令行创建数据库
1.创建数据库:CREATE DATABASE xf_test;2.授权test_user用户拥有xf_test数据库的所有权限,并为用户test设置密码:grant all on xf_test.* totest_user@'%' identified by 'test123' with grant option;...原创 2020-01-06 19:52:53 · 367 阅读 · 0 评论 -
mysql时间戳添加XX天
UPDATE `test` SET singer_expired_at = UNIX_TIMESTAMP(DATE_ADD(FROM_UNIXTIME(purchase_audit_at),INTERVAL 15 DAY)),merchant_expired_at=UNIX_TIMESTAMP(DATE_ADD(FROM_UNIXTIME(purchase_audit_at),INTERVAL ...原创 2019-11-29 12:03:39 · 907 阅读 · 0 评论 -
其他机器连接mysql数据库时提示没权限
grant all on test.* to root@'%' identified by 'xxxxxx' with grant option;flush privileges;本地用127.0.0.1连接不上show grants;grant all on test.*to root@'localhost'identified by 'xxxxxx'with grant o...原创 2020-02-17 17:48:02 · 267 阅读 · 0 评论