0

Hello Guys I want to connect two databases at the same time but it looks like the php is only picking up the second database.

One database is on my localhost and the other one is on server, I want to transfer the data from my localhost database to the database on the server. I have also tried passing the 4th argument to the mysql_connect function but I can't get it to work.
mysql_connect("localhost", "name", "password", true);

Please help me.

Thanks

6
Contributors
6
Replies
11
Views
8 Years
Discussion Span
Last Post by vamsy143
1

Hello Guys I want to connect two databases at the same time but it looks like the php is only picking up the second database.

One database is on my localhost and the other one is on server, I want to transfer the data from my localhost database to the database on the server. I have also tried passing the 4th argument to the mysql_connect function but I can't get it to work.
mysql_connect("localhost", "name", "password", true);

Please help me.

Thanks

This help you out..

$link=mysql_connect("localhost", "name", "password", true);
$link1=mysql_connect("localhost", "name", "password", true);

$mysql_query($qry,$link);
$mysql_query($qry1,$link1);

This the one.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.