I am facing this error at the time of configuration my laravel 6.2 project with PHP 7.2.5 to MSSQL SERVER and I have added in .env file
DB_CONNECTION=sqlsrv
DB_HOST="DESKTOP-AMCDA5K"
DB_PORT=1433
DB_DATABASE="AuditReferences"
DB_USERNAME="sa"
DB_PASSWORD="admin123"
DB_ENCRYPT=true
DB_TRUST_SERVER_CERTIFICATE=false
for view server connection page is here server login page
and I have added all dll files in php.ini file setting and pdo_sqlsrv, sqlsrv are shown in phpinfo page
$ php artisan migrate
Illuminate\Database\QueryException : could not find driver (SQL: select * from sysobjects where type in ('U', 'V') and name = migrations)
at C:\wamp64\www\Laravel\laravelProj\vendor\laravel\framework\src\Illuminate\Database\Connection.php:669
665| // If an exception occurs when attempting to run a query, we'll format the error
666| // message to include the bindings with SQL, which will make this exception a
667| // lot more helpful to the developer instead of just the database's errors.
668| catch (Exception $e) {
> 669| throw new QueryException(
670| $query, $this->prepareBindings($bindings), $e
671| );
672| }
673|
Exception trace:
1 PDOException::("could not find driver") C:\wamp64\www\Laravel\laravelProj\vendor\laravel\framework\src\Illuminate\Database\Connectors\Connector.php:70
2 PDO::__construct("dblib:host=DESKTOP-AMCDA5K:1433;dbname=AuditReferences;charset=utf8", "sa", "admin123", []) C:\wamp64\www\Laravel\laravelProj\vendor\laravel\framework\src\Illuminate\Database\Connectors\Connector.php:70