Reputation: 48798
I've inherited a huge project, and I'm having a real time just trying to get the damned thing on its legs. Every time I run the project, amongst all the Strict Standards
and Depreciated
notices is one error:
Failed opening 'MDB2\Driver\mysql.php' for inclusion
From what I've read, DBMS drivers stopped being included in default Pear installations over five years ago... So how I can fix this so that either it doesn't use mysql.php
anymore, or that my Pear installation DOES have it?
According to the Pear website, I just need to type: pear install MDB2_Driver_mysql
but I'm wondering if it wouldn't just be better to change the code?
Thanks!
Upvotes: 1
Views: 3016
Reputation: 3844
You say the project is huge, so I would suggest you don't rewrite it to use a different DB access library as that could push out your release date quite a bit and instead just install the required MDB2 driver.
To install the mysql driver, just do:
# pear install --alldeps MDB2_Driver_mysql
(and maybe consider using the mysqli driver instead)
If you do decide to migrate the project to use a different library, I'd suggest Doctrine as it is one of the mature DB libraries out there.
Upvotes: 1
Reputation: 94672
It sounds like you are trying to run PHP code written for an older version on a version of PHP that does not like some of the code.
Also see this for some insight on what you actually have to have installed on the PC running wamp in order to actually access a DB2 database. Are you sure you have all of this installed before you try to install via PECL?
Upvotes: 0