Persistant Connections MySQL
[email protected] (Lester Caine) Fri, 11 Dec 2009 07:16:11 +0000
| Newsgroups | php.pdo |
|---|---|
| Message-ID | <[email protected]> |
Guys There has been a short thread on php-db about sharing connections between mysql and PDO_mysql. The statement seems to be that both drivers will share a single persistent connection. Is this REALLY the case? What happens with mysqli which I understand is required for newer versions of MySQL? The 'advise' currently being given is that opening a mysql and a PDO_mysql connection with exactly the same credentials will share a single connection? And so does not increase the number of connections being used. The reason I am confused is that with PDO creating default transactions, how on earth can these be shared with another instance of the connection? I think this comes into any discussion on sorting out how PDO actually handles transactions and while I have no problem with reusing a previously opened connection from a pool, using the same connection potentially in different threads just seems crazy? -- Lester Caine - G8HFL ----------------------------- Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk// Firebird - http://www.firebirdsql.org/index.php