RE: [PHP] Database Handles
| From: | Samantha Savvakis | Date: | Wed, 06 Dec 2000 05:18:41 +0000 |
| Subject: | RE: [PHP] Database Handles | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-28849@lists.php.net to get a copy of this message | ||
Hi again,
I've done more investigation and I think there might an issue, or it's
something I'm doing completely wrong.
I've attached a simple program - test.php.
mysql_connect and mysql_pconnect are having the same effect.
Procedure: I open both handles to the database at the start. One to database
TEST1, and other the TEST2.
Despite the fact I'm sending to mysql_query(..) the database handle, it is
trying to use the last opened database for the query.
Here are the database scripts:
CREATE DATABASE TEST1;
CREATE TABLE TABLE1
(
TABLE1_ID integer not null auto_increment,
PRIMARY KEY(TABLE1_ID)
);
CREATE DATABASE TEST2;
CREAT TABLE TABLEA
(
TABLEA_ID integer not null auto_increment,
PRIMARY KEY(TABLEA_ID)
);
Sam