Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

export database structure

How can ai export database through PhpMyAdmin

but I need to export it as file that I run in PHP , such as here.

the reason I need it this way is because I can create stuff faster this way.

like image 631
homerun Avatar asked Mar 02 '26 15:03

homerun


2 Answers

Uncheck the data column once you've selected Custom - display all possible options :

enter image description here

like image 200
Sebastien Avatar answered Mar 05 '26 04:03

Sebastien


The method varies depending on the version of PHPMyAdmin you're using.

Older Version

Select the database you want to export and click on the 'Export' tab.

Click 'select all' above the table list, and uncheck the 'Data' field on the right hand side of the page.

Make sure the output format is set to SQL, and uncheck the 'Save as File' field if you just want to copy and paste the output.

Click 'Go'.

Newer, AJAX Version

Select the database you want to export and click on the 'Export' tab.

Select the 'Custom' option, click 'Select All' above the list of tables that appears.

Select the 'Save as File' option if you want to save the output, otherwise leave it as-is to copy and paste it.

Under 'Format specific options', select the 'Structure' option.

Click 'Go'.

like image 37
leemeichin Avatar answered Mar 05 '26 05:03

leemeichin