Search Postgresql Archives

Re: table synonyms

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, May 22, 2005 at 03:28:22PM -0300, jjeffman@xxxxxxxxx wrote:
> Of course! Maybe I am mixing users and schemas, because in Oracle they
> are the same, the schema has the name of the user which is the owner of
> the database tables and objects.
> 
> So the problem can be described as follows :
> 
> 1. Let be Ent01 an enterprise, and Ent02 a different one.
> 2. At Ent01 the database schema has the name "SCH01" and at Ent02 the
> database schema has the name "FOO" .
> 3. The same application must run in booth enterprises, and all the
> database queries and table names are the same, just the schemas has
> different names.
> 4. The application can run using a database user other then the tables
> owner, so the queries must be written using the coplete format
> (schema.table.column) .
> 
> Using Oracle I can set up synonyms for the tables and by pass the format
> above, or I can use a macro substitution (ODAC components) to use the
> correct schema name, setting it at runtime.

In PostgreSQL, you can get roughly the same behavior using search_path.
http://lnk.nu/postgresql.org/2r2.html

> By the way what "FWIW" stands for ?

For What It's Worth.
-- 
Jim C. Nasby, Database Consultant               decibel@xxxxxxxxxxx 
Give your computer some brain candy! www.distributed.net Team #1828

Windows: "Where do you want to go today?"
Linux: "Where do you want to go tomorrow?"
FreeBSD: "Are you guys coming, or what?"

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo@xxxxxxxxxxxxxx

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux