Re: how to refer to tables in another database( or schema as oracle refers to)

From: "Graeme Merrall" <gbmerrall(at)aol(dot)com>
To: <chriskl(at)familyhealth(dot)com(dot)au>, "Jiaqing" <jjw72(at)swbell(dot)net>, <pgsql-sql(at)postgresql(dot)org>
Subject: Re: how to refer to tables in another database( or schema as oracle refers to)
Date: 2002-08-20 02:47:29
Message-ID: MMEKJDBHGFPPMNBALCOHMEAMCDAA.GBMerrall@aol.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


> Basically - you can't. There is a program in the contrib/dblink directory
> that can help you though.
>

My take on this dblink program is to create SQL as a view.
For example coming from Oracle you might do "SELECT one, two, FROM foo.bar".
Convert that to a VIEW called simply "bar" or "foo_bar" that contains your
dblink query and there will be minimal chnages you'll have to make to your
actual code.
This could also be used to get around synonyms as well.

Cheers,
Graeme

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Stephan Szabo 2002-08-20 02:56:13 Re: how to refer to tables in another database( or schema as
Previous Message Christopher Kings-Lynne 2002-08-20 01:56:53 Re: Modify column type