From: | Eugene Yin <eugeneymail(at)ymail(dot)com> |
---|---|
To: | "pgsql-sql(at)postgresql(dot)org" <pgsql-sql(at)postgresql(dot)org> |
Subject: | public synonym |
Date: | 2016-01-07 20:17:40 |
Message-ID: | 358282890.1765953.1452197860946.JavaMail.yahoo@mail.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
PostgreSQL ver 9.4.5. Linux OS.Application: Web Based
Platform: App Server (java) --> jdbc call --> Database Server (PostgreSQL)
I do know that PostgreSQL does not support the public synonym. Now, for a user schema (let's call it MASTER_USER), if I coded in the stored function/procedure like the following, without using a public synonym to identify the table name:
select user_name from user_info_table
then access it from the Java (web app) side via the JDBC call to the database, will that work?
OR,
I must use the identifier inside the sql, such as:
select user_name from MASTER_USER.user_info_table?
I come from the Oracle world, there I first create the public synonym for the table, then in the stored procedure I just directly reference the table with no need to identify the table with a schema name. Like to know how it work under the PostgreSQL.
Thanks
Eugene
From | Date | Subject | |
---|---|---|---|
Next Message | Eugene Yin | 2016-01-07 20:22:26 | To get the column names, data types, and nullables of tables in the schema owned by MASTER_USER |
Previous Message | Adrian Klaver | 2016-01-06 00:34:28 | Re: [SQL] plv8 installation problem |