MySQL 笔记

创建新用户 create a new user

mysql> create user 'someuser'@'localhost' identified by 'somepassword';

创建新数据库 create new database

mysql> create database some_db_name

赋予用户使用权利 Grant privileges to a user

mysql> GRANT ALL PRIVILEGES ON database_name.* TO 'some_user'@'localhost';

参考资料

MySQL功能非常齐全,每个命令都有很多细节,本文只收集一下基本用法,更多可以看这个网页和官方文档。

Leave a Reply

Your email address will not be published. Required fields are marked *