I'm using Hibernate with JPA and MySQL.
I got accessing denied.
java.sql.SQLException: Access denied for user 'username'@'hostname' (using password: YES)
I know the username/password are ok. The problem is that is that the driver is appending @'hostname' at the end. How can I prevent that?
But the grant is only for username, and the machine are different, so I can't grant for every hostname. (I don't care if it's secure or not, it's a dev server).
I created the database that way:
create database mydbname character_set utf8 collate utf8_general_ci;
GRANT ALL ON mydbname.* TO username IDENTIFIED BY 'password';