Ran into this issue again from starting over, yet managed to fix it with
php artisan migrate:refresh php artisan config:cache
Hope this helps someone if they experience this issue.
@NAKOV - same issue presented when ran: php artisan migrate
Yes, I have important data within the database. I have cloned my Laravel app and DB, so nothing is affected if I run into issues.
I know both Laravel App and voyager are trying to use the same SQL table as settings that is why I see this error, but I can not update to use a prefix such as abcsettings because my laravel app cannot read SQL table if prefix is changed in .env file. It seems easy when you first read the SQL error, yet no workaround.
My next attempt is to export data out of my SQL DB, then delete, install voyager and then dump exported SQL back into DB, I'll post results after.
N16h7h4wk started a new conversation SQLSTATE[42S01]: Base Table Or View Already Exists ? Install Admin Panel Issue !
Attempting to install Voyager on Laravel 5.4 using the same SQL database as Laravel app.
These are the steps I took for installation:
1: cd /laravel_app 2: composer require tcg/voyager 3: My .env already has my DB credentials 4: My app_url within .env is: APP_URL=http://localhost:8000 5: Since I am running 5.4 I added serviceprovider within config/app.php
/* * Package Service Providers... */ Laravel\Tinker\TinkerServiceProvider::class, TCG\Voyager\VoyagerServiceProvider::class, /* * Application Service Providers... */
6: php artisan config:clear (If I don't do this before install I get Voyager command not found and or voyager namespace not a registered class)
7: php artisan voyager:install
This is what follows:
Publishing the Voyager assets, database, and config files Copied Directory [/vendor/tcg/voyager/publishable/assets] To [/public/vendor/tcg/voyager/assets]
Copied Directory [/vendor/tcg/voyager/publishable/database/seeds] To [/database/seeds]
Publishing complete. Publishing complete. Migrating the database tables into your application
Application In Production! *
Do you really wish to run this command? (yes/no) [no]:
In Connection.php line 647:
SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'settings' already exists (SQL: create table
id int unsigned not null auto_increment primary key,
key varchar(191) not null,
display_name varchar(191) not null,
value text not null,
details text null,
type varchar(191) not null,
order int not null default '1') default character set utf8mb4 collate utf8mb4_unicode_ci)
In PDOStatement.php line 107: SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'settings' already exists
In PDOStatement.php line 105: SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'settings' already exists
Other things I have tried are:
Voyager is visible when I run php artisan
My goal is to use Voyager admin with my Laravel app Any help is greatly appreciated
@AMIRHAZZ - I had attempted this first when I ran into this issue. I ended up starting the install process again. Thanks for your help.
N16h7h4wk started a new conversation Class App\Providers\AppServiceProvider Not Found Within ProviderRepository.php
Running Laravel 5.4
I updated the namespace of our Laravel app and now I get this error with all commands using artisan:
In ProviderRepository.php line 208: Class 'App\Providers\AppServiceProvider' not found
I reverted back to the original namespace of app and still having this issue.
My question is how do you properly register this class within ProviderRepository.php? I can not find clear instructions unless someone can direct me in the right direction.
I am fairly new to Laravel, so I do apologize for sounding like a Noob.