Databases
phpMyAdmin
Updated: 10 February 2024
cPanel Version: 118
phpMyAdmin is a free and open-source tool written in PHP intended to handle the administration of MySQL with the use of a web browser. It can perform various tasks such as managing databases, tables, columns, relations, indexes, users, permissions, etc. In this tutorial, we will delve into how to create, manage, and delete tables using the phpMyAdmin menu on cPanel.
Accessing phpMyAdmin on cPanel
Before we start, you need to know how to access phpMyAdmin on cPanel:
- Log into your cPanel account.
- Under the Databases section, click on the phpMyAdmin icon.
- In the new tab, you should see the phpMyAdmin dashboard.
Creating Tables
Creating a new table in phpMyAdmin is straightforward. Here's how:
- In the phpMyAdmin dashboard, select the database where you want to create the new table from the list on the left.
- Under the Create table section, enter the name of your new table and specify the number of columns you need.
- Click the Go button.
- You will be redirected to a new page. Here, you can specify the details for each column, including name, type, length, and other attributes.
- After filling in the column details, click Save to create your new table.
Managing Tables
Now that you've created a table, you might want to manage it. Here's what you can do:
- Select the table you want to manage from the left sidebar.
- With the table selected, you will see several tabs at the top: Structure, SQL, Search, Insert, etc.
- To insert records, click on the Insert tab. Fill in the fields with the data you want to insert, then click Go at the bottom.
- To edit records, go to the Browse tab. Here, you can navigate through your records. Click the Edit button (pencil icon) to edit any record.
- To delete a record, go to the Browse tab, find the record you want to delete, and click the Delete button (trash bin icon).
Inserting Records
Editing Records
Deleting Records
Deleting Tables
If you no longer need a table, you can delete it. Follow these steps:
- From the left sidebar, click on the table you want to delete. This will open the table view.
- At the top of the screen, click on the Operations tab.
- Under the Table options section, you'll find the Delete the table (DROP) option. Click on it.
- phpMyAdmin will ask you to confirm your decision because this operation cannot be undone. If you're sure, click Yes.
Note
Always be careful when deleting tables, as this action cannot be undone.