
mysql -u root -p

create database "database명";

create user 'user명'@'127.0.0.1' identified by 'password';
'database명'@'접속위치'
127.0.0.1으로 할경우는 localhost, 내부 접속에서의 권한만 갖는다.
grant all privileges on cafe.* to 'user명'@'127.0.0.1';
flush privileges;


반응형
'데이터베이스' 카테고리의 다른 글

mysql -u root -p

create database "database명";

create user 'user명'@'127.0.0.1' identified by 'password';
'database명'@'접속위치'
127.0.0.1으로 할경우는 localhost, 내부 접속에서의 권한만 갖는다.
grant all privileges on cafe.* to 'user명'@'127.0.0.1';
flush privileges;


반응형