sign458
sign458

Reputation: 55

Laravel 7 database seed command not success

working with laravel 7 and using php artisan db:seed command to table seed. then in terminal displayed database seed succesfully message. but not data table filled with data. how could I fix this problem? my existing database seedr.php file is

<?php

use Illuminate\Database\Seeder;

class DatabaseSeeder extends Seeder
{
    /**
     * Seed the application's database.
     *
     * @return void
     */
    public function run()
    {
        // $this->call(UsersTableSeeder::class);
    }
}


Upvotes: 1

Views: 406

Answers (1)

Syazany
Syazany

Reputation: 220

If you have multiple seeder class then use an array

 $this->call([
        CompaniesTableSeeder::class,
        DepartmentsTableSeeder::class
 ]);

Upvotes: 2

Related Questions