Problem in App Service Provider

Posted 8 months ago by herrygallery


In Providers - App Service Provider, I wrote :

View::share('publicoption', DB::table('options')->first());

Then I manually drop all of my tables from XAMPP including Options table above to test my migration and seed. Then got error :

SQLSTATE[42S02]: Base table or view not found: 1146

If I delete the above code in the App Service Provider, everything works OK.

Is my code wrong? Do I have to adjust the code in App Service Provided to refresh my tables?


Please sign in or create an account to participate in this conversation.

Laracasts Mascot

Hi, Have We Met Yet?

Did you know that, in addition to the forum, Laracasts includes well over 1000 lessons on modern web development? All for the price of one lunch out per month.

Sign Me Up


Reply to

Use Markdown with GitHub-flavored code blocks.