I am working in laravel 5.5 with postgras 9.6, I manage to run all migration and rollback, but when I want to run migration for rename a column in Table i get the Class 'Doctrine\DBAL\Driver\PDOPgSql\Driver' not found
error, hire is migration file:
class CreateRenameApplicantIdInBillToApplicationId extends Migration
{
public function up()
{
Schema::table('bill_bills', function($table) {
$table->renameColumn('applicant_id', 'application_id');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('bill_bills', function($table) {
$table->renameColumn('applicantion_id', 'applicant_id');
});
}
}
Any help would be appreciated.
To renaming columns Laravel 5.x, you need to require doctrine/dbal package in your composer.json file.
composer require doctrine/dbal
I think this will help you. Thanks.
For PHP 7 in Linux you can install driver via
sudo apt-get install php7.0-pgsql
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With