Performance of DB Link VS Public Synonyms

1) In a single database(Oracle 9.2) , I have multiple schema say a, b ,c d ,e etc.Currently we are using public synonyms to access tables of other schema.There is a plan to split the database into two or three DB and to use db links instead of public synonyms.So what would be impact on performance?
2) In a same database for accessing multiple schema objects which one between DB link and Synonym is a better approach and why? How are the working mechanism for each of them?
Appreciate your quick response.

MSINHA wrote:
No, on the same server we will have different instances. We are trying to split the schema into separate DB so as to independently upgrade them as they are for different applications and modules but some of the tables are common and being accessed using public synonym.Horrible idea to run multiple database instances on a single server. This is not how servers scale.
Oracle scales by adding more servers to a single database - this is called RAC.
Your approach is the exact opposite. Adding more databases to a single server.
That approach seldom makes any technical sense - and is usually forced by circumstances (like running 2 different Oracle versions) and not by sound technical, performance and scalability reasons.
Keep in mind that an Oracle database is NOT architecturally and technically the same as a mySQL or SQL-Server database. A mySQL/SQL-Server database is called a schema in the Oracle environment.

Similar Messages

  • Create a public synonym for a db link - "Connection desccriptor not found".

    I want to create a public synonym for a db link.
    The existing db link name is tst.world ( which is in db links table and is working fine).
    I created the following db link using the following command:
    create public synonym "syn.world" for "tst.world";
    It created the synonym successfully.
    If I try the following, it throws error "Connection desccriptor not found".
    select * from [email protected];
    It says "Connection desccriptor not found".
    Any suggestions.
    Thanks in Advance.

    Well then, lookup the Documentation on the CREATE SYNONYM statement in the SQL Language Reference manual.
    The documentation lists the types of objects which you can create synonyms for.
    You can create synonyms for objects referenced across DBLinks.
    You cannot create synonyms for DBLinks.
    Hemant K Chitale

  • DB Links vs. Public Synonyms Security issue

    I have been debating on using either a public synonym or a db link for my purpose. I have a dev, test, and prod database. I have applications that have been developed using a public synonym. I know that if I were to switch to db links I would have to go back and change the applications to have access to the tables. I was wondering if it would be more secure to just have the public synonyms with select privilege or have db links. I need to decide if I should use db links for various users in the same DB (e.g. prod) and to use db links from one DB to another. Can someone explain what the security risks are between the two and which would be safer to use?
    Thanks

    I appreciate that you have taken the time to read my post. The version of the database I am using is 10g. I guess to clarify my post I am asking if someone can provide me advantages and disadvantages of using either public synonyms or db links. I don't know if I am clear, but when I refer to a DB Link I am referring to the following type of access where a client in a database A can access information in a remote database B (e.g. schema1.table2@databaseB). I am not sure what you mean by "Database links are two entirely different technologies that do two entirely different things". But I would appreciate if someone with DBA experience can provide some insight regarding security issues associated with using public synonyms and db links.
    Thank you,

  • DB Link Public Synonym

    Hi Guys
    I have a public SYNONYM that was created to access a table on the remote database using a DB Link.
    We are able to access the DB Link using SQL Plus and the Synonym BUT when the same is used inside the cursor query of a PL/SQL block we get the following error message!
    This is driving me crazy... need your expert suggestion :)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Errors for PROCEDURE SP_PROCESS_SESEBA031:
    59/12 PLS-00341: declaration of cursor 'V_CUR' is incomplete or
    malformed
    60/9 PL/SQL: ORA-01775: looping chain of synonyms
    60/9 PL/SQL: SQL Statement ignored
    95/15 PL/SQL: Item ignored
    123/9 PL/SQL: SQL Statement ignored
    124/18 PLS-00320: the declaration of the type of this expression is
    incomplete or malformed
    127/9 PL/SQL: Statement ignored
    127/12 PLS-00320: the declaration of the type of this expression is
    incomplete or malformed
    148/13 PL/SQL: SQL Statement ignored
    161/37 PL/SQL: ORA-00904: "V_DTL_REC"."TRADE_DATE": invalid identifier
    161/37 PLS-00320: the declaration of the type of this expression is
    incomplete or malformed
    180/9 PL/SQL: Statement ignored
    180/53 PLS-00320: the declaration of the type of this expression is
    incomplete or malformed
    182/9 PL/SQL: SQL Statement ignored
    213/14 PLS-00320: the declaration of the type of this expression is
    incomplete or malformed
    213/24 PL/SQL: ORA-00984: column not allowed here
    Compile source: /usctreg1/app/db/proc/SP_PROCESS_SESECRC.src
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Thanks & Best Regards,
    Faisal.

    Hi,
    As I say, when we access the synonym (that links to a table through a DBLINK) we have this issue. The code can be as simple as
    DECLARE
    var1 int := 0;
    CURSOR S1 IS SELECT col1, col2 from TB_DBLINK;
    BEGIN
    LOOP through Cursor S1
    END;
    Here the TB_DBLINK is:
    CREATE PUBLIC SYNONYM TB_DBLINK FOR TB_DBLINK@DBL1
    The TB_DBLINK on the DBL1 is also a Public Synonym... So it means that a Public Synonym is being created for a Public Synonym!
    Able to access this using SQL Plus simple select though :(

  • Grants problem in public synonym created though Database link

    Hi all,
    I have created the public synonym by using the table in the remote db in schema A.
    create public synonym test_syn for test_syn@rating.
    Now I want to grant a another user (say B) to access privillages on test_syn.
    (unable to grant the sysnonym using grant select on test_syn to B )
    Database link has been created by the user A.
    Please lat me know how I can grant select on synonym test_syn to B in this case.
    Thanks and regards
    Buddhike

    I think you should grant right on the original object (test_syn@rating)

  • Export Database Link & Public Synonyms using Expdp

    Dear All,
    We are using expdp to do schema level exports:
    expdp dumpfile=<Directory>:expdp.dmp SCHEMAS=S1,S2,S3
    We also want to export the Public/Private Synonyms (created for the objects owned by above users), Public/Private Database Links as part of above command.
    How we can achieve this? We are using 11gR2.
    regards,
    Riaz

    HI,
    Public synonym can not be exported and never exported even at FULL Export also. . You can get them from "dba_synonyms". I suggest that you create so customer script .
    select      'create public synonym ' || table_name || ' for ' || table_owner || '.' || table_name || ';'
    from      dba_synonyms
    where
         owner='PUBLIC' and table_owner not in ('SYS', 'SYSTEM')
    order by
         table_owner;
    More: Information:
    https://forums.oracle.com/thread/855639?start=0&tstart=0
    Oracle Data Pump Schema Export and Public Synonyms
    Thank you

  • JDev app wizard unable to see public synonyms

    When running through reverse engineering to create middle-tier entities/views/assoc/links, the wizard was unable to give me the option of choosing from among public synonyms. I checked under SYSTEM, SYS users but the synonyms I wanted did not appear.
    When I created non-public synonyms in a schema, JDev did find them.
    PS: The synonyms access tables and views on another server using database links.
    null

    Are you logging on as yourself or as the owner of the objects? If you are logging on as yourself then you will only see the objects owned/created by you.
    If you want to see objects owned by other users click "other users" and click on the user that owns the objects that you want to view. If you do not have 'select' privs on the object then you will not be able to see the object in another users account.

  • Public Synonym in Expdp

    Oracle:11.2.0
    OS: Windows
    Is it possible to export public synonym with the help of expdp utility?
    If not, what is the reason behind this?
    Thanks,
    AKPT

    No it is not possible. You can run the following scriptm spool it and run it on a desired database
    select 'create public synonym ' || synonym_name ||
           ' for ' || table_owner || '.' || table_name || ';'
    from dba_synonyms
    where owner = 'PUBLIC'
    and table_owner = 'THAT USER'
    Also, if you want to export using expdp, you can read the following link
    http://www.dadbm.com/2012/01/how-to-export-public-database-objects-with-oracle-data-pump/

  • Hyper link of public image(hyperlink or image) can not be saved on windows server 2012 and sharepoint 2010 problem

    hyper link of public image(hyperlink or image) can not be saved on windows server 2012 and sharepoint 2010 problem, is this a bug?
    thanks for any reply.
    Rosone

    It is not a bug, you might be using IE in Windows server 2012 and and browser might be restricting your site actions to respond properly.
    Check this in a different browser or access site in a differ OS.
    Adnan Amin MCT, SharePoint Architect | If you find this post useful kindly please mark it as an answer.

  • Create a view based on a public synonym

    Hi I'm trying to create a view based on a public synonym, but getting "ORA-01031: insufficient privileges" error.
    When i retrieve records from the same public synonym, i could able to do so. But when i try to create a view based on that synonym, it is not possible. Why is it? Can anyone please explain?
    11:58:04 IT00053.it0053@SCOTT> connect sys as sysdba
    Enter password: ******
    Connected.
    11:58:14 IT00053.it0053@SYS> create role general_user_role;
    Role created.
    Elapsed: 00:00:00.14
    11:58:33 IT00053.it0053@SYS> connect scott
    Enter password: *****
    Connected.
    11:58:41 IT00053.it0053@SCOTT> select * from tab;
    TNAME TABTYPE CLUSTERID
    DEPT TABLE
    EMP TABLE
    BONUS TABLE
    SALGRADE TABLE
    DEPT_TAB SYNONYM
    Elapsed: 00:00:00.01
    11:58:47 IT00053.it0053@SCOTT> create public synonym scott_emp for scott.emp;
    Synonym created.
    Elapsed: 00:00:00.06
    11:59:14 IT00053.it0053@SCOTT> grant select on scott_emp to general_user_role;
    Grant succeeded.
    Elapsed: 00:00:00.14
    11:59:35 IT00053.it0053@SCOTT> connect sys as sysdba
    Enter password: ******
    Connected.
    12:00:13 IT00053.it0053@SYS> create user beginning_user
    12:00:31 2 identified by beginning_user
    12:00:38 3 default tablespace users
    12:00:45 4 temporary tablespace temp;
    User created.
    Elapsed: 00:00:00.04
    12:00:53 IT00053.it0053@SYS> grant connect, resource, create table, create view to beginning_user;
    Grant succeeded.
    Elapsed: 00:00:00.01
    12:01:13 IT00053.it0053@SYS> grant general_user_role to beginning_user;
    Grant succeeded.
    Elapsed: 00:00:00.01
    12:01:35 IT00053.it0053@SYS> connect beginning_user/beginning_user
    Connected.
    12:01:49 IT00053.it0053@SYS> connect beginning_user
    Enter password: **************
    Connected.
    12:02:01 IT00053.it0053@SYS> show user
    USER is "BEGINNING_USER"
    12:02:06 IT00053.it0053@SYS> select * from scott_emp;
    EMPNO ENAME JOB MGR HIREDATE SAL
    COMM DEPTNO
    7369 SMITH CLERK 7902 17-DEC-80 800
    20
    7499 ALLEN SALESMAN 7698 20-FEB-81 1600
    300 30
    7521 WARD SALESMAN 7698 22-FEB-81 1250
    500 30
    7566 JONES MANAGER 7839 02-APR-81 2975
    20
    7654 MARTIN SALESMAN 7698 28-SEP-81 1250
    1400 30
    7698 BLAKE MANAGER 7839 01-MAY-81 2850
    30
    7782 CLARK MANAGER 7839 09-JUN-81 2450
    10
    7788 SCOTT ANALYST 7566 19-APR-87 3000
    20
    7839 KING PRESIDENT 17-NOV-81 5000
    10
    7844 TURNER SALESMAN 7698 08-SEP-81 1500
    0 30
    7876 ADAMS CLERK 7788 23-MAY-87 1100
    20
    7900 JAMES CLERK 7698 03-DEC-81 950
    30
    7902 FORD ANALYST 7566 03-DEC-81 3000
    20
    7934 MILLER CLERK 7782 23-JAN-82 1300
    10
    14 rows selected.
    Elapsed: 00:00:00.21
    12:02:16 IT00053.it0053@SYS> create or replace view new_view_1 as select empno, ename, job from
    12:02:50 2 scott_emp;
    scott_emp
    ERROR at line 2:
    ORA-01031: insufficient privileges
    Why is this error?
    Your help will be much appreciated...
    Thanks and regards
    Muthu

    create any view privilege
    10:15:07 IT00053.it0053@SYS> connect sys as sysdba
    Enter password: ******
    Connected.
    10:22:27 IT00053.it0053@SYS>
    10:22:28 IT00053.it0053@SYS>
    10:22:28 IT00053.it0053@SYS> grant create any view to beginning_user;
    Grant succeeded.
    Elapsed: 00:00:00.00
    10:22:53 IT00053.it0053@SYS> connect beginning_user/beginning_user
    Connected.
    10:22:59 IT00053.it0053@SYS> create or replace view new_view_1 as select empno, ename, job from scot
    t_emp;
    create or replace view new_view_1 as select empno, ename, job from scott_emp
    ERROR at line 1:
    ORA-01031: insufficient privileges
    ---> Same result
    But When creating a view, the owner must have granted the select directly.
    10:23:08 IT00053.it0053@SYS> connect scott/tiger
    Connected.
    10:25:43 IT00053.it0053@SCOTT> grant select on scott_emp to beginning_user;
    Grant succeeded.
    Elapsed: 00:00:00.07
    10:26:14 IT00053.it0053@SCOTT> connect beginning_user/beginning_user
    Connected.
    10:26:19 IT00053.it0053@SCOTT> create or replace view new_view_1 as select empno, ename, job
    10:26:25 2 from scott_emp;
    View created.
    Elapsed: 00:00:00.03
    This works. Thanks a lot for your timely help.
    danke shun herr bochum. thanks to mr.ankara

  • What can i do for creating view on a public synonym?

    Hi people,
    I have create a public synonym for other users object as,
    SQL> create public synonym pdep for scott.dept;
    Synonym created.
    then i tend to create a view on this public syn as,
    SQL> create view vpdep as select * from pdep;
    create view vpdep as select * from pdep
    ERROR at line 1:
    ORA-01031: insufficient privileges
    I have privilege to create view.also i can create view on a public synonym of my own objects.for ex,
    SQL> create public synonym cdep for dept;
    Synonym created.
    SQL> create view vcdep as select * from cdep;
    View created.
    what could be the reason behind this?is there any privilege required for me.pls suggest me.
    Regards
    VIDS

    Hi vidusnat!
    This is from Oracle's onlinedocumentation:
    >
    Privileges Required to Create Views
    To create a view, you must meet the following requirements:
    You must have been granted one of the following system privileges, either explicitly or through a role:
    o The CREATE VIEW system privilege (to create a view in your schema)
    o The CREATE ANY VIEW system privilege (to create a view in another user's schema)
    You must have been explicitly granted one of the following privileges:
    o The SELECT, INSERT, UPDATE, or DELETE object privileges on all base objects underlying the view
    o The SELECT ANY TABLE, INSERT ANY TABLE, UPDATE ANY TABLE, or DELETE ANY TABLE system privileges
    In addition, in order to grant other users access to your view, you must have received object privileges to the base objects with the GRANT OPTION clause or appropriate system privileges with the ADMIN OPTION clause. If you have not, then grantees cannot access your view.
    >
    I hope that this will bring a little light into darkness!
    Yours sincerely
    Florian W.

  • Do I need to deploy Public Synonym in Target Schema?

    Hi,
    I need to develop and deploy a mapping. I need to use source table in source schema but a Public Synonym for a terget table. This destination table for the public synonym is not target_schema where mapping is to be deployed. Do I still need to deploy the public synonym into my target schema where mapping is or not? I was 3wandering since its a public synonym and the actual destination table is already in database I may not have to deploy this synonym. Thanks for the help in advance..

    OWB does not currently directly support public synonyms. You will have to deal with these synonyms outside OWB and if you use the synonym from a mapping you can trick OWB to use it by creating and using a dummy table in the mapping.
    Regards:
    Igor

  • Problem in CR XI returning Views with PUBLIC synonyms

    I am having problem in CR XI returning Views with PUBLIC synonym.
    I can see the tables and stored procedures with PUBLIC synonym but not VIEWS.
    This is a simple View that has a PUBLIC synonym to it. I have granted the user SELECT access to the underlying Views.
    I checked the boxes in Report > Options for all the combinations possible one by one but to no avail.
    I connect CR to the instance as a specific user , password. But when I go to Views (and Tables) there is nothing visible.
    I tried PRIVATE synonyms and when I go to Views (and Tables) the views are visible, but now the Fields are not visible.
    In SQL+ and Oracle SQL Developer connected as the same user , password everything looks ok.
    Any help will be appreciated.

    Hi Wayne,
    Sorry for the delay. Not sure where this post came from.... must have been transferred from another forum.
    R1 is no longer support nor are updates available. You can upgrade to CR Xi R2 for free, it's end of life now also but has all of the latest patches included.
    Install with your XI R1 keycode and then test again.
    http://downloads.businessobjects.com/akdlm/crystalreports/crxir2_sp4_full_bld_0-20008684.exe
    http://downloads.businessobjects.com/akdlm/crystalreports/CRYSTALREPORTS06_0-20008684.EXE
    Thank you
    Don

  • Access Views through Public Synonyms

    Hi Friends,
    I have query need to clear. My current application is running on a schema *(s1)* associated with workspace *(w1)*. Now i have made one more schema *(s2)* in the same workspace *(w1)* where i have to create new tables.
    The thing is i want to use few tables column of s1 on s2. What will be the best practice for this. I have made views of columns of s1 schema and now i am thinking to create public synonym in s2 schema to access those views of s1 schema. Just want to confirm any changes or updates made on forms or report made on synonym of s2 will reflect in the base table (which is table of s1). Want to clear the concept of synonym through this. I am sure it will not update the table of s1 schema because i have made synonym of that in my s2 schema and for all page creation i am using objects of s2 not objects of s1.
    Would like to hear from you experts on this. If you have some other better soln for this, do suggest me. All my intension is to not update the tables of s1, just to use the required columns of s1 schema objects and use it in s2 schema
    Regards
    Edited by: User_Apex on Jul 7, 2010 2:21 AM
    Edited by: User_Apex on Jul 7, 2010 2:28 AM

    Hi,
    A synonym just helps you to avoid using the schema name before the object name. If you want to use some columns from tables in s1 just do the following:
    1. Create the views
    2. Create a role for that privilege (for example: select_s1_role), grant select to this role over the views and assign it to s2.
    3. Create the synonym in s2 to s1 views (just to avoid put s1. before the view name).
    For the steps above is required that s1 and s2 have the proper system privileges.
    Kind regards,

  • Public Synonyms...

    SQL> show user
    USER is "SYS"
    SQL> select * from dba_synonyms where synonym_name = 'BANK';
    OWNER SYNONYM_NAME TABLE_OWNER TABLE_NAME
    PUBLIC BANK SEGERP BANK
    AMCTESTLHR BANK AMCERPTEST BANK
    SQL> conn rakesh/rakesh@testapp
    Connected.
    SQL> select * from bank;
    select * from bank
    ERROR at line 1:
    ORA-00942: table or view does not exist
    SQL>
    Why Didn't rakesh can access the bank [Public Synonym] It can be accessed by any schema?

    Synonyms (public or private) are just aliases for an object. They do not imply permission to use that object for a particular user.
    In your case, any user (except amctestlhr) can do select * from bank and get data from segerp.bank provided they are allowed to select from that table. Without the public synonym, all user who had select privilege would need to either create their own private synonym, or do select * from segerp.bank.
    John

Maybe you are looking for