Issue with the doctrine-cli
I am having issues getting my database to build from my YAML file.
Here is the error:
./scripts/doctrine-cli build-all-load
build-all-load - Generated models successfully from YAML schema
build-all-load - Couldn't locate driver named mysql
build-all-load - Created tables successfully
build-all-load - Data was successfully loaded
It 开发者_StackOverflow社区builds my models, but nothing in the database. I am using MAMP and I have checked and pdo_mysql is running. I am not completely sure why this would happen. Thank you.
This quite looks like pdo_mysql
is not enabled ; you said you checked php.ini
, but did you check the one that's used when PHP is run from the command line ?
(That's often not the same as the one used when PHP is run as an Apache module)
You can use php -m
to get the list of loaded extensions :
$ php -m
[PHP Modules]
bcmath
bz2
...
pcre
PDO
pdo_mysql
...
And php -i
should indicate which .ini file is used, when running PHP from the CLI :
$ php -i | grep 'ini'
Configuration File (php.ini) Path => /etc/php5/cli
Loaded Configuration File => /etc/php5/cli/php.ini
Scan this dir for additional .ini files => /etc/php5/cli/conf.d
additional .ini files parsed => /etc/php5/cli/conf.d/apc.ini,
/etc/php5/cli/conf.d/curl.ini,
...
精彩评论