Share Share on Facebook Share on Twitter Pinterest Email It seems Laravel is trying to use category_posts table (because of the many-to-many relationship). But you don't have this table, because you've created category_post table. Change the name of the table to category_posts. LaravelLaravel 6Laravel 7 0 Siddharth Shukla Website Related Posts SQLSTATE[HY000] [2002] Connection refused within Laravel August 31, 2021 How to Check Laravel Version via CLI August 27, 2021 Laravel 8 Compare Two Carbon Dates August 24, 2021 How to make laravel 8 Shopping Cart August 22, 2021 Write A Comment Cancel Reply Save my name, email, and website in this browser for the next time I comment.