I have often wanted to do this.  Years ago, when I was working with Sybase databases it was perfectly possible.  You simply qualified the table name with a database identifier as I recall eg

SELECT m.myfield from second_db.mytable m;

The advantages are that you may have two otherwise unconnected systems which need separately backing up etc but where one uses the other for lookup purposes (eg a reservations system uses a lookup to an accounts system to get the customer name and number). 

I have never understood why postgreSQL hasn't seen this as a priority in development in more recent months.  Maybe someone will enlighten us both!

Hilary

At 11:18 08/07/2004 -0400, Jodi Kanter wrote:

I am working with someone who uses MySQL and says that he has two separate databases in which he can query across. I am curious if that is something that can be done in postgres?
Any comments on whether or not that is a good thing?
Thanks
Jodi Kanter
--

_______________________________
Jodi L Kanter
BioInformatics Database Administrator
University of Virginia
(434) 924-2846
jkanter@virginia.edu


 

 

 

Hilary Forbes
The DMR Information and Technology Group  (www.dmr.co.uk)
Direct tel 01689 889950 Fax 01689 860330
DMR is a UK registered trade mark of DMR Limited
**********************************************************