Page 1 of 1
Multiple database Connections
Posted: Mon Sep 12, 2005 9:03 am
by vivekjain
Hi,
I would like to know if I can connect to 2 different database using PHP. I need to access different tables from different database.
Thanks
Posted: Mon Sep 12, 2005 9:13 am
by shiznatix
have you tried it?
Mutiple db connection
Posted: Mon Sep 12, 2005 9:19 am
by vivekjain
yes, I am getting this error:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL
Posted: Mon Sep 12, 2005 9:26 am
by feyd
very very likely, you have an error in your query syntax.
mysql_error()
Posted: Mon Sep 12, 2005 11:38 am
by BDKR
LOL! You may want to check that you connect with success before going forward with the query.
multiple database connection
Posted: Tue Sep 13, 2005 12:32 am
by vivekjain
It works now, I had to use the databse name.tablename and it worked.
thanks