Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

laravel migration change column order

public function up()
{

    DB::statement("ALTER TABLE example MODIFY COLUMN foo DATE AFTER bar");

}

public function down()
{

    DB::statement("ALTER TABLE example MODIFY COLUMN foo DATE AFTER bar");

}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #laravel #migration #change #column #order
ADD COMMENT
Topic
Name
8+9 =