Results 1 to 3 of 3
Hybrid View
-
06-07-2002, 11:08 PM #1Junior Guru Wannabe
- Join Date
- May 2001
- Posts
- 81
Joining tables from 2 databases in MySQL
Anyone know if it's possible to join 2 tables from 2 different databases in MySQL?
-
06-07-2002, 11:16 PM #2Web Hosting Master
- Join Date
- Jan 2002
- Location
- Melbourne, AU
- Posts
- 740
This may be of some help.
Lats...
-
06-08-2002, 12:00 AM #3Web Hosting Master
- Join Date
- Jun 2001
- Location
- Earth
- Posts
- 1,259
As long as the user has permissions in both databases I belive it's quite easy:
select a.col_1, b.col_2
from db1.table_1 a,
db2.table_2 b
where a.col_3 = b.col_3
Just fully qualify the table name with the db name.
Frank█ Umbra Hosting
█ cPanel | Softaculous | CloudLinux | R1Soft | Ksplice
█ Web Hosting, Reseller Hosting, VPS, Dedicated Servers, Colocation
█ UmbraHosting.com