Re: postgresql database access failure

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Florin Jurcovici wrote:
> My personal recommendation, however, is to drop old-style procedural
> drivers and switch to PDO - it's much more convenient to use, IMO.

Just be careful.  PDO's implementation of MySQL doesn't implement the
mysql_set_charset() function, or at least it didn't a while back according to
my reading the PDO source.  Setting a charset in the DSN was possible, but PDO
didn't *do* anything with that setting.  There are probably other minor holes
out there.  ("Everything in these tables is UTF-8!"  "Are you *sure* about
that?  It looks a lot like CP-1252 here, and here, and here....")

> you use PDO, you don't need to study the API of various different DB
> drivers, and your code can easily switch from one database to another.

This is true to some extent.  There are probably a few odd cases where the
native functions do more, or do it better than whatever the latest and
greatest layer of abstraction does.

-- 
Matt G / Dances With Crows
The Crow202 Blog:  http://crow202.org/wordpress/
There is no Darkness in Eternity/But only Light too dim for us to see


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux