Home » Database » DB » Bug #1905
Patch : Use new_link with mysql_connect
Details
| Request #1905 | Patch : Use new_link with mysql_connect |
|---|---|
| Submitted | 2004-07-17 19:48 UTC |
| From | hmn at newz dot dk |
| Assigned | danielc |
| Status | Closed |
| Package | DB |
| PHP Version | Irrelevant |
| Roadmaps | (Not assigned) |
Comments
[2004-07-17 19:48 UTC] hmn at newz dot dk
Description:
------------
The mysql module run mysql_select_db every time a query is executed. This is done to support connections to several databases in the same script, but in mysql_connect (from php 4.2) the option new_link has been added so that you can force creation of a new link.
I have added code to DB/mysql.php that uses the new_link option instead of doing a mysql_select_db for every query.
Reproduce code:
---------------
http://area-51.dk/files/pear-db-mysql.diff