mysql創建表空間和用戶


創建表空間名

create database 空間名 default character set utf8 collate utf8_bin;

創建用戶
create user 用戶名 identified with mysql_native_password by '密碼';

給用戶賦權(上面設置了用戶密碼,則賦權時不需要再設置密碼)
grant all on 空間名.* to '用戶名'@'%' identified with mysql_native_password by '密碼';
grant select,insert,update,delete,create,drop on vtdc.employee to 用戶名 identified with mysql_native_password by '密碼';


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM