1php artisan make:migration add_paid_to_users_table --table=users
2
3public function up()
4{
5 Schema::table('users', function($table) {
6 $table->integer('paid');
7 });
8}
9
10public function down()
11{
12 Schema::table('users', function($table) {
13 $table->dropColumn('paid');
14 });
15}
16
17php artisan migrate
1Schema::table('users', function ($table) {
2 $table->string('email')->after('id')->nullable();
3});
1Schema::table('users', function (Blueprint $table) {
2 $table->dateTime('verify_date')->nullable()->after("password_updated_at");
3});
1// The table method on the Schema facade MAY BE USED TO UPDATE EXISTING TABLES.
2// The table method accepts two arguments: the name of the table and a Closure
3// that receives a Blueprint instance you may use to add columns to the table:
4Schema::table('users', function (Blueprint $table) {
5 $table->string('email');
6});