≡ Menu

Making a Table for MySQL Database in PhpMyAdmin’s User Interface

Sometime you accidentally deleted or wrecked a table in phpmyadmin by being careless, so you need to recreate the table, or restore your database in Phymyadmin.

Maybe you need a MySQL table for your web app which need a place to store data like blog posts which is imputed by a user.

The easiest way to create or recreate a table is to use Phpmyadmin table creator found in Phpmyadmin Database table listings.

Using the GUI interface of PhpMyadmin to create tables can also be a good way to learn SQL code since PhpMyAdmin outputs the SQL code used to create the table which you can reuse to create tables on other databases with the SQL command box in PhpMyAdmin

1. Log in to your control panel /Cpanel for your webhosting account.

2. Look for the Database section after you log in.

3. Find the database you want to administrate. Click on the Phpymyadmin link next to the database. Backup your database since changes are permanent and you can’t undo changes.

4. Click the Database link on the left sidebar with the name of your database with (numble of tables) in brackets.

Database link in sidebar

5. At the bottom of the database window, there is a small box called “Create new table on database Database Name” where you can make a Table with a unique name and give you the option to create 1 or more fields. Fields are just text boxs for your table. A field can be an ID number, first name, last name, year, etc.

Type in your table name and how many fields you want in the form, and click Go button.

Name your database and type in numbe of fields you need

6. Type in your field names, and set the options for the fields in your database table. Click the save button to save your new database table. If you need more fields type in the number of extra fields you need and click Go otherwise click save to finalize the table creation process.

type in field names and adjust settings

7. The finish result will look like this. I recommend saving the SQL code to a text file, so you can easily recreate it with the SQL Command box in Phpmyadmin by clicking the SQL button in phpmyadmin by using this code:

CREATE TABLE `14778_phpbb3`.`Table_Name` (
`id` VARCHAR( 100 ) NOT NULL ,
`name` VARCHAR( 100 ) NOT NULL ,
PRIMARY KEY ( `id` ) ,
INDEX ( `name` )


The table name and link should now appear on the left sidebar of PhpMyAdmin sidebar.

If you need help with SQL or MySQL I recommend getting a book on mySQL or reading some tutorials on mySQL tables at dev.mysql.com/doc/refman/5.1/en/create-table.html

2 comments… add one
  • sumyat July 26, 2012, 3:59 am

    In my phpmyadmin page, i want to create new table ,but there is no table name box in phpmyadmin’s interface.
    Pls advice me.

  • Johnson Yip July 27, 2012, 1:03 am

    You have to click the main database name, and at the bottom there should be a create table box. I’m using 1and1 web hosting, so maybe newer versions of phpmyadmin on other web hosts don’t have the feature.

    It is best to contact your web host to see if they can give you instructions on how to create a new table on your database.

Leave a Comment