Hello,

Have you taken a look at the FEDERATED storage engine?

http://dev.mysql.com/doc/refman/5.0/en/federated-storage-engine.html

It is a storage engine that accesses data in tables of remote databases
rather than in local tables.  

Thanks,

Jimmy Guerrero
Sr Product Manager
MySQL, Inc

-----Original Message-----
From: Bing Du [mailto:[EMAIL PROTECTED] 
Sent: Friday, May 05, 2006 4:09 PM
To: mysql@lists.mysql.com
Subject: possible to select from multiple databases?

Hello,

I have two separate databases that I need to query data from.  In the
following SELECT statement, 'title' and 'db_entry_name' are in database1,
and 'projectID' is in database2.  If they were in one database, this SELECT
should work.  How should I tweak it to get data from both database1 and
database2?  Is that even possible in single SELECT?

SELECT title, db_entry_num, projectID FROM account_info, ResearchProjects
WHERE ResearchProjects.IDNo = $idno AND account_info.db_entry_num =
ResearchProjects.projectID

Thanks in advance,

Bing

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to