I’ve been using PHP & MySQL for ages and am about to start using PostgreSQL instead.
What’s the preferred method?
Is it via the PDO objects or is there something better?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
PDO objects are the new hotness. I’d recommend that as long as you can ensure that your target platform will always be running PHP 5.2+.
There are many other database abstraction layers that support PostgreSQL that are compatible with older versions of PHP; I’d recommend ADODB.
You should really be using PDO or a different abstraction layer even for your MySQL work; that way you won’t have this problem again!