Cross database queries - Mailing list pgsql-general

From postgresql@bryden.co.za
Subject Cross database queries
Date
Msg-id 35283.127.0.0.1.1123597269.squirrel@localhost
Whole thread Raw
Responses Re: Cross database queries
Re: Cross database queries
List pgsql-general
Hi

Suppose I have two databases on one server (lets call them DB_A and DB_B)
and I was to write a cross database query. How do I do this in PostgreSQL?

On MS-SQL I would do something like:

SELECT ta.Field1, ta.Field2, tb.Field2
FROM DB_A.dbo.SomeTable ta
JOIN DB_B.dbo.SomeOtherTable tb
  ON ta.Field1 = tb.Field1

Thanks
Craig

pgsql-general by date:

Previous
From: Csaba Nagy
Date:
Subject: Re: Query stucked in pg_stat_activity
Next
From: Lowell.Hought@faa.gov
Date:
Subject: Database syncronization