Once you create a MySQL Database, you will need to Add a User to theMySQL Database in order to make it work.
The following steps will show you how to Add a User to a MySQL Database.
First, you need to make sure that you have created the MySQL Database that you would like to add the user to. For that article, please click here.
In the MySQL® Databases inside cPanel, scroll down to MySQL Users.
1) We must create the user to Add to the MySQL Database.
To do this, fill out the fields pictured above by creating a Username and Password. The prefix to the MySQL user will be your Username.
Note: Make sure to make note of your MySQL User login credentials, as scripts will require them in their configuration files.
For this example, we're going use to the Username "example" followed by a secure password.
2) Click Create User (pictured below):
3) After you have created the user, you will see this screen:
4) Click the blue Go Back link.
Now we will Add the User jtyson_example to the jtyson_example1 (the MySQL database we created in this example)
5) Select both the name of your User and Database you want to Add. We listed our values above, notice they are selected in the dropdown menus pictured below.
Click the blue Add button pictured above.
6) Once that is complete, we'll assign the User Privileges on the next page.
In our example, we're going to assign the user "ALL PRIVILEGES" by checking the box. You can see what we did in the image below:
Click the blue Make Changes button and you have successfully added a user to a MySQL database and specified privileges. A green success message will appear confirming the completed task.