I tried a lot to import the sql script to create database and tables through phpmyadmin in the new site I hosted. But i'm getting the error,
1044 - Access denied for user 'user'@'localhost' to database 'db'
I tried to create a sample db directly : create database sampled; I'm getting the same access denied error.
I'm not able to grant privileges to the user also, i'm getting the same access denied error.
Following is the output of show grants command,
show grants;
GRANT USAGE ON . TO 'someuser'@'localhost' IDENTIFIED BY PASSWORD 'somepw'
GRANT ALL PRIVILEGES ON someuser\_%.* TO 'someuser'@'localhost'
Any help would be appreciated. thank you.
Edit the MySQL options file (typically /etc/my. cnf on Linux systems). Add the option to disable enforcement. This should go anywhere below the [mysqld] option group in the option file.
If you are using Godaddy then don't directly go to phpMyAdmin and run the sql command.
You have to go to MySQL® Databases section and create a database there. Then create a user and give it the permission to access the database you just created. Now you can go to phpMyAdmin and write your SQL commands.
Hope this helps
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With