29 Mar 2022

How to migrate a particular table in laravel | Laravel Migrate Specific File(s) from Migrations

 First you should create one migration file for your table like:

public function up() { Schema::create('test', function (Blueprint $table) { $table->increments('id'); $table->string('fname',255); $table->string('lname',255); $table->rememberToken(); $table->timestamps(); }); }


php artisan migrate --path='database\migrations\2022_03_29_062120_file_name.php' 

No comments:

Post a Comment