📜  laravel 迁移更新表列类型 - PHP 代码示例

📅  最后修改于: 2022-03-11 14:54:18.707000             🧑  作者: Mango

代码示例2
Schema::table('users', function ($table) {
    $table->string('name', 50)->change();
});
We could also modify a column to be nullable:

Schema::table('users', function ($table) {
    $table->string('name', 50)->nullable()->change();
});