Home  >  Q&A  >  body text

Symfony 6/Doctrine - DriverException: Driver not found

I try to setup my symfony project and everything is fine as I try to create the doctrine database. I wrote the DATABASE_URL in the .env file, which is correct, I think so, but neither my local xampp server nor my web server works.

I always get the same error:

[critical] Error thrown while running command "doctrine:database:create". Message: "An exception occurred in the driver: could not find driver"


In ExceptionConverter.php line 119:

  An exception occurred in the driver: could not find driver


In Exception.php line 30:

  could not find driver


In Driver.php line 28:

  could not find driver


P粉729518806P粉729518806246 days ago620

reply all(1)I'll reply

  • P粉198814372

    P粉1988143722024-01-22 14:18:57

    You may not have enabled the pdo_mysql extension in your php.ini file. Try uncommenting the line ;extension=pdo_mysql in php.ini.

    Please note that your php console may use a different php.ini file than the one you are running your application from.

    reply
    0
  • Cancelreply