This article is a step-by-step to learn how to edit a MySQL database or its user.
MySQL Databases (Rename Database)
- Inside cPanel, we click on the MySQL Database Wizard button under the Databases header (see image below)
- Next, we will scroll down to Current Databases, here you can select your database and click the Rename button. (see image below)
- When we click the button, a modal dialog box will appear where you can set your new database name (see image below).
- You click the Proceed button to finish renaming your database.
NOTE: When you do, you need to ensure to update all your physical files which point to the database name if there are any.
MySQL Databases (Rename User)
- Inside cPanel, we click on the MySQL Databases button under the Databases header (see image below)
- Next, we will scroll down to Current Users, here you can select your user and click the Rename button. (see image below)
- When we click the button, a modal dialog box will appear where you can set your new database name (see image below).
- You click the Proceed button to finish renaming your database user.
NOTE: When you do, you need to ensure to update all your physical files which point to the database user if there are any.
MySQL Databases (Change User Password)
- Inside cPanel, we click on the MySQL Databases button under the Databases header (see image below)
- Next, we will scroll down to Current Users, here you can select your user and click the Change Password button. (see image below)
- When we click the button, we will see a page like the one below. You will fill in the required fields and then click the Change Password to finish setting a new password for the database user.
- You are done, you have now set a new password for your database user.
NOTE: When you do, you need to ensure to update all your physical files which point to the database user if there are any.
How to Check/Repair a Database
- Inside cPanel, we click on the MySQL Databases button under the Databases header (see image below)
- (This is not really a step, just an explanation of using the Repair function) Often we can run into some issues with our websites, many times they are WordPress based and a database table is faulty, and your site may look like this example below
This is just an example, what can help is to follow step (1) and then go on to step (3). - Next, we will scroll down to Modify Databases, here you can select two functions, those functions are the following (see image below):
– Check Database: This will check your database only, it will not attempt to repair damages
– Repair Database: This will check and attempt to repair broken tables. - You are done, if it finds any table broken it will attempt to repair it or explain to you if it did not manage to get it repaired.