当前位置:网站首页>MySQL用户管理
MySQL用户管理
2022-07-23 05:41:00 【夏日入侵bug企划】
MySQL用户管理
两种方法:1、可视化软件操作;2、SQL命令
SQL命令
创建用户
create user 用户名 identified by '密码';修改密码
//修改当前用户密码 set password=password('新密码'); //修改指定用户密码 set password for 用户名=password('新密码');用户重命名
rename user 旧用户名 to 新用户名;用户授权
grant all privileges on *.* to 数据库名;//给数据库的表授予全部权限(除了给别的用户授权,root用户可以)查看权限
show grants for 数据库名;//查看指定用户的权限 show grants for root@localhost;//查看管理用户权限 //root用户权限设置源码: GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' WITH GRANT OPTION撤销权限
revoke all privileges on *.* from 数据库名;//撤销所有权限
边栏推荐
猜你喜欢

upload-lab第1~4关

User defined MVC usage & addition, deletion, modification and query

美联储布拉德:上周就业报告表明美国经济稳健,可以承受更高的利率

Adding environment variables and templates to systemctl service

数字藏品系统开发/数字藏品方案介绍

NFT digital collection platform development and construction, source code development digital collection

Basis of penetration test

Machine learning algorithm for large factory interview (5) recommendation system algorithm

数字藏品系统开发:企业布局元宇宙数字藏品

Kubesphere haproxy+kept (I)
随机推荐
Two sorting and one random data fetching of stored procedures
数字藏品系统开发:百度AI致敬中国航空
Entrepôt de données 4.0 Notes - acquisition de données sur le comportement de l'utilisateur II
MySQL Index & execution plan
Fed Brad: last week's employment report showed that the U.S. economy is robust and can withstand higher interest rates
[doris] configure and basically use the contents system (continue to add content when you have time)
sql实现连续登陆7天以上用户统计
[pyautogui learning] screen coordinates and mouse scrolling
ETH转账次数达到一个月高点
ES操作命令
数字藏品开发/数字藏品系统开发解决方案
Activiti7 Quick Start experience sharing
Setting optimization and use of MySQL and SQL Server
Unable to negotiate with port 51732: no matching host key type found. Their offer:
upload-lab第1~4关
[hudi]hudi compilation and simple use of Hudi & spark and Hudi & Flink
MySQL functions & views & import and export
mysql树形结构递归查询
數倉4.0筆記——用戶行為數據采集四
Security problems of FileInfo in PHP file upload