Noob Coder
Noob Coder

Reputation: 2917

Laravel database seeding

I am trying to use the database seeder feature. But its not inserting the row, nor even showing any error.. I need suggestion please. Laravel version 5.2.29 enter image description here

Upvotes: 0

Views: 389

Answers (2)

Abhishek
Abhishek

Reputation: 3987

Do this:

php artisan db:seed --class= UserstableSeeder

Moreover whenever you create a new seeder file don't forget to run

composer dump-autoload

Upvotes: 2

Surreily
Surreily

Reputation: 36

It looks like your DatabaseSeeder isn't calling UserstableSeeder. Try putting something like this into your DatabaseSeeder:

$this->call(UserstableSeeder::class);

Upvotes: 2

Related Questions