MySQL Error-om.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Access denied for user 'codelab'@'localhost' to database 'codelab'

CODEDRAGON Development/Database

반응형



 

 

오류메시지

com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Access denied for user 'codelab'@'localhost' to database 'codelab'

 

 

 

 

오류원인

권한 부족

 

 

 

해결방법

GRANT ALL PRIVILEGES ON *.* TO 'codelab'@'localhost' IDENTIFIED BY 'mysql_pw' WITH GRANT OPTION;

mysql> GRANT ALL PRIVILEGES ON *.* TO 'codelab'@'localhost' IDENTIFIED BY 'mysql

_pw' WITH GRANT OPTION;

Query OK, 0 rows affected, 1 warning (0.00 sec)

 

mysql>