Answers for "laravel migration column length"

PHP
6

laravel migration remove column

public function up()
{
  Schema::table('table', function($table) {
    $table->dropColumn('column_name');
  });
}
Posted by: Guest on April-16-2020
1

laravel migration change column length

Schema::table('users', function ($table) {
    $table->string('name', 50)->change();
});
Posted by: Guest on November-19-2020

Code answers related to "laravel migration column length"

Browse Popular Code Answers by Language