Search code examples
mysqlsqlphpmyadminxampp

Change column order in MySQL


Is it possible to change the order of columns in MySQL (using phpMyAdmin XAMPP) by which they appear without dropping the current table?


Solution

  • Try this

    ALTER TABLE `table_name`
        MODIFY COLUMN `column_name1` varchar(100) AFTER `column_name2`;