Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MySQL re-arranging order of columns with phpmyadmin

Any help on re-ordering the columns in MySQL using phpMyAdmin? Is it called cardinality? I have created tables, but need to re-arrange the order of the columns due to an export script i have. It exports based on the arrangements. E.g. I want columns:

Apple | Cherry | Banana 

changed to:

Apple | Banana | Cherry 
like image 230
karto Avatar asked Jun 02 '11 19:06

karto


People also ask

How do I reorder columns in MySQL?

Go to Structure and click Move Columns and then just drag the columns to rearrange.

How do I rearrange tables in phpMyAdmin?

In phpMyAdmin go to table structure. On bottom you can press option "Move columns" There you can rearange tables as you see fit. That one is for rearranging columns, not the tables themselves.

How do I change the order of rows in phpMyAdmin?

Just go to PHPmyadmin, click on your database, then click table. Then click on structure. Below the table look for the button, "Move columns". Click and order the columns the way you want.


1 Answers

phpMyAdmin has finally included this feature in the most recent version (4.0 and up).

Go to the "Structure" view for a table, click the Change button on the appropriate field, then under "Move column" select where you would like the field to go.

like image 189
DisgruntledGoat Avatar answered Sep 17 '22 17:09

DisgruntledGoat