user

Joseph Morgan

16 Aug 2022

SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'failed_jobs'

Laravel

Hello everyone, 
I just start using Laravel Queue and when I run this command to create the failed Jobs table 

php artisan queue:failed-table

then run migrate:fresh

php artisan migrate:fresh

It return this error 

SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'failed_jobs'

SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'failed_jobs'

How can I figure out this issue?

Comments

Mohamed Atef

16 Aug 2022

Best Answer

best answer
githubgithubgithub

It seems that you are using Laravel x9 and In Laravel 9 you don't have to create the failed_jobs table using this command because it already exists once you install a new Laravel application 9v. so please remove this migration and check your DB and you will find that the table is already there.
Good Luck

Replies

Joseph Morgan

16 Aug 2022

Thank you so much, First time to notice this

© 2024 Copyrights reserved for web-brackets.com