Public synonym for DBA only?

Is it true that only DBA can create public synonyms?
Or is it better for a DBA to publish it rather than other users? Is it because it is the responsibility of the DBA or what? Thank you.

Published by: 801264 on December 17, 2010 20:35

Everyone can 'CREATE a PUBLIC SYNONYM':
http://download.Oracle.com/docs/CD/E11882_01/server.112/e17118/statements_9013.htm#i2155015

And it should be someone who knows what is happening in all of the database. Sometimes it's s/n, but above all, there is a technical project manager who knows the need for application much better.

Tags: Database

Similar Questions

  • Which granted CREATE a PUBLIC SYNONYM for user SCOTT?

    version: 11.2.0.3
    Operating system: Solaris 10

    Auditing is enabled in our database.
    SQL> show parameter audit_trail
     
    NAME                                 TYPE        VALUE
    ------------------------------------ ----------- ------------------------------
    audit_trail                          string      DB
    Of DBA_SYS_PRIVS, we have confirmed that one of our DBA colleagues gave some risky privileges like CREATE PUBLIC SYNONYM, SELECT ANY TABLE... etc. to the user SCOTT.

    We would like to find out 2 things
    1. the SQL GRANT
    2. the date and time on which the statetement GRANT was pulled


    How can we find it?

    Y.Ramlet wrote:
    version: 11.2.0.3
    Operating system: Solaris 10

    Auditing is enabled in our database.

    SQL> show parameter audit_trail
    
    NAME                                 TYPE        VALUE
    ------------------------------------ ----------- ------------------------------
    audit_trail                          string      DB
    

    Of DBA_SYS_PRIVS, we have confirmed that one of our DBA colleagues gave some risky privileges like CREATE PUBLIC SYNONYM, SELECT ANY TABLE... etc. to the user SCOTT.

    We would like to find out 2 things
    1. the SQL GRANT

    You will have no SQL in the audit trail, because you have not configured the parameter correctly. You must audit_trail = db, extended to get the SQL code.

    2. the date and time on which the statetement GRANT was pulled

    You will have anything unless you have enabled auditing for the instruction given with
    Check create public synonym;

    How can we find it?

    You can't until you configure the audit in an appropriate manner.

  • What can I do for the creation of a public synonym view?

    Hi people,
    I create a public synonym of another object to users

    SQL > create public synonym PAPD for scott.dept;


    The synonym is created.

    so I tend to create a view of this public syn

    SQL > create view vpdep in select * from PAPD.
    Create view vpdep in select * from PAPD
    *
    ERROR on line 1:
    ORA-01031: insufficient privileges

    I have the privilege to create view.also, I can create views of a public synonym for my own ex objects.for,

    SQL > create public synonym cdep for dept.

    The synonym is created.

    SQL > create view vcdep in select * from cdep;

    Created view.

    What could be the reason behind this? is there any privilege required to me.pls suggest me.

    Concerning
    VIDS

    Hi vidusnat!

    It is onlinedocumentation to Oracle:
    >
    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 by a role:
    o CREATE The VIEW system privilege (to create views in your schema)
    o The CREATE ANY VIEW system privilege (to create a view of another user schema)
    You must explicitly obtained one of the following privileges:
    o the SELECT, INSERT, UPDATE, or DELETE object privileges on all objects in the view's underlying base
    o SELECT it ANY TABLE, INSERT a WHOLE TABLE, UPDATE ANY TABLE or DELETE ANY TABLE access privileges

    In addition, in order to grant access to your display of other users, you must have privileges to object to the base with the OPTION GIVING clause objects or system privileges with ADMIN OPTION clause. If you do not, users cannot access your view.
    >

    I hope that this will bring a little light in the darkness!

    Yours sincerely

    Florian W.

  • Public synonyms in a pluggable database deletion

    I have a base Oracle container 12 c with pluggable databases in it.  In a pluggable data bases, I uninstalled OLAP by running the following scripts:

    SQL > @%oracle_home%/olap/admin/catnoamd.sql

    SQL > @ /olap/admin/olapidrp.plb% oracle_home %

    SQL > @ /olap/admin/catnoxoq.sql% oracle_home %

    SQL > @ /olap/admin/catnoaps.sql% oracle_home %

    After you run the scripts, I then generated SQL statements to remove invalid OLAP synonyms, by executing the following:

    Select ' drop public synonym ' | object_name | ';'

    from dba_objects

    where <>of status "VALID."

    and owner = 'PUBLIC '.

    and object_type = 'SYNONYM '.

    and object_name like '% OLAP % ';

    When I run the SQL statements resulting in the snap-in data base, I get the following error for each of them:

    ERROR on line 1:

    ORA-65040: operation not allowed a pluggable database

    If I switch back to the ROOT of PEH container $ and executes the same statements, I get the following error:

    ERROR on line 1:

    ORA-01432: due public synonym being abandoned does not exist

    How can I remove these invalid public synonyms for my snap-in database?

    I think you're right. I re-read the note that I mentioned above. Even uninstalling an option is not supported for a CBD so far. Only option is to disable it. Second option is to create a non - CBD, uninstall option is not required and then plug it into a CBD.

    Salman

    ----------

    http://salmandba.blogspot.com

  • public synonyms

    Hello

    my database name is sch.in I have two patterns named ownr and database user.

    I've created tables, packages in ownr. I have to offer subsidies to these tables and packages to the schema of the user.

    If I create public synonyms for all tables and packages in the ownr schema are there the subsidies needed to access these objects from the user scehma?

    user10447332 wrote:
    Hello

    my database name is sch.in I have two patterns named ownr and database user.

    I've created tables, packages in ownr. I have to offer subsidies to these tables and packages to the schema of the user.

    If I create public synonyms for all tables and packages in the ownr schema are there the subsidies needed to access these objects from the user scehma?

    YES, in all THAT Oracle is FORBIDDEN; except as explicitly granted.

    SYNONYM is NOT a GRANT

    Handle: user10447332
    Status level: Beginner
    Join date: October 20, 2008
    Messages total: 322
    Total Questions: 215 (194 pending)

    Why so MANY unanswered questions?

  • PUBLIC SYNONYM - strange behavior

    I just organized a test on SQL queries for my students.

    It is based on four tables in a schema, and I created public synonyms for each table and read privilege to the PUBLIC, for example

    Staff CREATE a PUBLIC SYNONYM FOR testuser.staff
    GRANT SELECT ON testuser.staff to PUBLIC

    All the 150 + of my students have exactly the same roles and privileges, and yet two could not access the table of personnel without to refer to him as testuser.staff. They were able to access as provided for in the past.

    Has anyone encountered this before? I can't imagine that it's something to do with 60 students hit the synonym even at the same time, but I wonder.

    Brian

    Oracle Database 11 g Enterprise Edition Release 11.2.0.1.0 - 64 bit Production
    PL/SQL Release 11.2.0.1.0 - Production
    CORE 11.2.0.1.0 Production
    AMT for 64-bit Windows: Version 11.2.0.1.0 - Production
    NLSRTL Version 11.2.0.1.0 - Production

    Hello

    Both users apparently have their own tables (views, synonyms, or other objects) called the STAFF.

    What kind of results do get when they use the unqualified name, like this

    SELECT  last_name
    FROM    staff;
    

    ? "If they get"ORA-00904"'Name': invalid identifier", it might be because their own staffing table is not a column named LAST_NAME.

    A name to your own schema takes precedence over a PUBLIC synonym. It makes sense: you don't want all your own queries on your own STAFFING table to stop just because someone used the same name for a public synonym.

  • name of the permission for ' drop public synonym '.

    We fall synonymous public as:
    GRANT DROP PUBLIC SYNONYM TO User1;
    How the permission/role is named to run this statement?
    What table I can query to see if my connected user has this right?
    I googled but did not.

    You must DROP PUBLIC SYNONYM privilege.

    You can determine if your username has this privilege by running the following query:

    SELECT *
    FROM   dba_sys_privs
    WHERE  grantee   = 'your user here'
    AND    privilege = 'DROP PUBLIC SYNONYM'
    ;
    
  • Synonyms for invalid public Oracle XE

    Hello

    I wondered why these public synonyms will always invalid in my Oracle XE?
    SQL> select object_name from dba_objects where status != 'VALID';
    
    OBJECT_NAME
    --------------------------------------------------------------------------------
    DBA_HIST_FILESTATXS
    DBA_HIST_SQLSTAT
    DBA_HIST_SQLBIND
    DBA_HIST_SYSTEM_EVENT
    DBA_HIST_WAITSTAT
    DBA_HIST_LATCH
    DBA_HIST_LATCH_MISSES_SUMMARY
    DBA_HIST_DB_CACHE_ADVICE
    DBA_HIST_ROWCACHE_SUMMARY
    DBA_HIST_SGASTAT
    DBA_HIST_SYSSTAT
    
    OBJECT_NAME
    --------------------------------------------------------------------------------
    DBA_HIST_SYS_TIME_MODEL
    DBA_HIST_OSSTAT
    DBA_HIST_PARAMETER
    DBA_HIST_SEG_STAT
    DBA_HIST_ACTIVE_SESS_HISTORY
    DBA_HIST_TABLESPACE_STAT
    DBA_HIST_SERVICE_STAT
    DBA_HIST_SERVICE_WAIT_CLASS
    
    20 rows selected.
    I installed XE on Ubuntu 9.04. I have changed default installation is that I put to level Apex 3.2 and archiving on the value.

    BR, Jari

    Please see BUG 3603160

  • Privileging the public synonym over schema object

    Hello

    I have a request.

    I logged in a scheme called "SCOTT."

    I have a table called 'EMP '.

    Now, I created a view called "EMP_D" with the addition of more of a few columns.

    Now I create a public synonym 'EMP' pointing to display "EMP_D".

    Now, I'm pulled the query in the schema "SCOTT."

    Select * from EMP

    I want that data to the EMP_D view.

    How to get there?

    Thanks in advance

    S. Jean-Charles

    user629814 wrote:

    My question is

    is it possible to prioritize the resulting public synonym of the same schema?

    Its only for a solution.

    This is called "name resolution" and is documented here: http://docs.oracle.com/cd/B28359_01/server.111/b28310/general008.htm#ADMIN11561

    1 oracle database attempts to qualify the first piece of the name referenced in the SQL statement. For example, in scott.emp , scott is the first piece. If there is only one piece, the piece is considered to be the first piece.

    1. In the current schema, the database looking for an object whose name matches the first part of the name of the object. If it does not find such an object, it continues with step b.
    2. The database looking for a public synonym that matches the first part of the name. If it does not find one, it continues with stepc.
    3. ...

    So if you have a schema object with the same name as a public synonym, oracle will always use first the schema object.

    Your only chance would be to rename the schema object or use another schema.

  • 2 various CARS: same Public Synonyms on the same 2 diagrams - any interaction?

    I'm having a senior moment.

    I have not worked with public synonyms that often, so I just want to make sure I got it right.

    If you have two instances: Instance1 and Instance2

    They both live on the same Oracle RAC cluster.

    Intance1 and Instance2 have a schema named FRED.  Both of them have a synonym Public THISTABLE for FRED. THISTABLE

    Now, I want to just make sure that the public synonyms do NOT connect between two different, although instances on the same RAC system, right?

    Someone on Instance2 inserting in fred.thistable is ONLY for this instance, instance1 do not affect all, correct?

    You would have to do something like this, essentially a database link between them and could have a public link THISTABLE on Instance2 pointing to FRED. THISTABLE on Instance1... but simply want to make sure that I understand that only a dblink between two patterns on the two bodies will... allow traffic/access between the two bodies and public synonyms on their own will not cross the instance gap, even with two instances on the same cluster.

    Once again, senior moment here and just want to make sure I have it directly.

    Thanks in advance,

    Cayenne

    This case I put in place the same pattern of FRED and the same FRED table name. TABLEAUCETTE on the database instance instsqa... There is no link between the two with this public synonym on instdev. The only way you could link the two instances and schemas for the table would be by a... correct database link?

    Yes. You got right.

    Take CARS out of it.  It's the same as if you had 2 databases one-off names instdev and instqa.

    Post edited by: Brian Bontrager

  • no access Public Synonym

    create or replace procedure proc_s
    -return varchar2
    is
    v_Name varchar2 (20);
    Start
    -immediate execution "select name from r_temp where id = back 4: I ' using v_name;"
    SELECT name in v_name from r_temp where id = 4;
    -return (v_name);
    dbms_output.put_line (v_Name);
    end;

    r_temp is the public synonym but this code generates the PL/SQL compilation error: ORA-00942: table or view does not exist
    While that select * from r_temp code to return all rows

    But: the synonym is pointing to an underlying object: table.

    "You can reference only synonymous with another user by using the privileges of the object that you got." For example, if you have the right to SELECT for the synonym of jward.emp, then you can query the synonym of jward.emp, but you cannot insert rows using the synonym of jward.emp. »
    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14231/views.htm#sthref3138
    Where my previous question.

  • API public Oracle for loads of Internet - approval and reject functionality

    Hello

    Is there a public API to Oracle for expense - approval and reject functionality?

    I couldn't find one, the only way to reproduce the functionality of the EBS is using workflow.

    I'm looking at one for EBS - R12.1 and R12.2.

    Thank you

    Rohit

    Had opened a SR with Oracle Support to find out if there is a public API for the expense report - approval and reject functionality.

    Currently there is no, but Oracle has open an enhancement request.

    Bug 20423007 : PUBLIC FOR APPROVAL of SPENDING INTERNET API - APPROVE AND REJECT FEATURES

    If you are looking for the note of fresh - approve and reject the public API, please refer to the enhancement request.

    Thank you

    Rohit

  • Generate public names for all attributes?

    Hi all

    What suggestions do you generate public names for all attributes in OPM 10.4?

    We try to the pretty square of the record of decision by setting invisible all attributes, except for: the goal first, structural reference number and database.

    Looks like the only way to do is to go in the model of generation and manually create the public name one by one.

    Thank you

    Isamu

    Unfortunately, you are right and it is difficult to create public names for intermediate attribute as a bulk operation.

    You can retrieve the part of how to compile each document in turn, and then by creating public names for the document and then remove the xgen before moving on to the next-, but this will not help you with the attributes that are intermediate in the document rules - but it will get you the way which (unfortunately I see you want to keep the legal references, so if you use structural elements that mean that by they) are intermediate in their own documents).

    Another common technique is that when there is common text used in different segments that you create a public file names of model for this * all * attributes and make a copy of the model, then do a search and replace (in a text editing tool). That has been my main approach on projects where I need to give intermediate attributes a public name - it is absolutely vital to the attribute naming conventions right (and is often what you get taken into account from the design of modules - so a little more difficult to retro-actively to implement).

  • DBMS - data not visible for read only account users.

    I created below to know the status of my lots which run on server every Sunday.

    CREATE OR REPLACE VIEW CAFDB_REFRESH AS
    SELECT
    log_id,
    owner,
    TO_CHAR (log_date, ' ' DD-MON-YY HH24:MI:SS) TIMESTAMP.
    job_name,
    status,
    ERROR #.
    run_duration,
    INSTANCE_ID,
    additional_info
    Of user_scheduler_job_run_details;

    It works fine and I am able to get the information.
    now, to make it visible for read only account users - using «grant select» I gave access and created also means public.

    but it shows only the names of columns in read only account data.

    How to make this visible to read only account?

    Please guide.

    Views USER_ will have only the objects owned by the user executing the query... In your case, it will be only schedules made by the user.

    You will need EU ALL_ or view s/n (all_scheduler_job_run_details)

  • How to revoke all privileges on a public synonym of a user

    How to revoke all privileges on a public synonym of a user in 9i?

    you know the difference between PRIVATE and PUBLIC means?

    Public synonyms are accessible to all users.
    Private is accessible only inside its schema.

    If you do not want this user, use this synonym drop it and create a synonym in other schemas where users need.

Maybe you are looking for

  • Disk utility will not let me click on the partition.

    I've updated to El Capitan, disk utility since refuses to let me click on partition. Accidentally, I partitioned my disk flash before I updated and so I need to cancel, because now I have 200 MB of storage on it. I tried using terminal but I have bee

  • Should I keep all service packs on my system, when I install a newer version?

    2 service packs 2 & different MB.s one can only have been downloaded and installed do not. I have windows xp SP3, also of .net framework 2.0 & 3.0, the two service Pack2.  Do I have to keep the two service pack 2 on my computer alone with my service

  • Unable to find a way to set up mail to windows mail servers

    Im trying to get an email set up, no hotmail, windows or one of those other normal, I want a windows or e-mail thingy, but I can't understand how the thing of mail servers everything works, im so lost, I tried windows help thing and still could not u

  • Lack of VWiFi Windows 7

    Since the departure of Windows 7 Release Candidate (build 7100) 32-bit with Windows 7 Professional 32 bit bought from windows7.digitalriver.com I have more Microsoft Virtual WiFi Miniport Adapter is on my list of network connections. The computer I u

  • More large viewfinder of the camera to reduce size of output?

    When you change the size of the video output of the images from the camera (reminder) I had to change the size of the camera and viewfinder... But is there a way to keep the large poster viewfinder? I can't open two viewfinders?