欢迎各位兄弟 发布技术文章
这里的技术是共享的
public function up(){
DB::statement('ALTER TABLE items MODIFY COLUMN item_description TEXT');
DB::statement('ALTER TABLE items MODIFY COLUMN delivery_description TEXT');
}
public function down(){
DB::statement('ALTER TABLE items MODIFY COLUMN item_description VARCHAR(255)');
DB::statement('ALTER TABLE items MODIFY COLUMN delivery_description VARCHAR(255)');
}
来自 http://stackoverflow.com/questions/22060398/how-do-i-change-a-column-type-with-laravel-schema-builder
http://laravel.io/forum/04-07-2014-changing-the-length-of-a-column-using-migrations