Viewing package/proc/funtion source in other schemas

There still seems to be some problems with viewing PL/SQL source in other schemas. In TOAD, I can grant SELECT ANY DICTIONARY to a developer and they can see all source in other schemas. In SQL Developer, they see nothing. If I grant EXECUTE ANY PROCEDURE, they can see the package specs, but no body (Note: we do not want developers having this priv).
Again, our developers need to be able to view the PL/SQL source in other schemas, without having execute privs on said objects, which is very easy in TOAD. I see this issue in many threads, but SQL Developer seems to have not progressed in this area (unless I'm doing something wrong).

Granting select on dba_source has no affect. Sure, they can get the code from the table, but it would be nice to browse to it in the GUI. Even with "execute any procedure", the package bodies are not visible.
I've seen similar tools that have this same issue, but somehow the developers of TOAD got it right, a long time ago even. This is the only issue that keeps our development team from jumping on board with this tool.

Similar Messages

  • Wwsec_api packaged procedures not accessed by other schema user.

    I am trying to use wwsec_api packaged procedure in portal application developed in another users schema and owned by that user. When I try to execute wwsec_api procedures it gives numeric or value error.
    could anyone tell what all permissions/grants to be set to access security package in other user's schema's portal application?

    Have you tried running provsyns.sql? It's detailed in the PDK.

  • Error using views from other schema

    Hello,
    i recently had problems using the execute immediate statement in Object Types.
    The SQL statement tried to select from some views which were owned by an other schema.
    Although we had public synonyms on these views and the same dynamic sql could be used out of a stored procedure the usage in the object type raised a "table or view does not exist exception".
    using the same views in the same schema where the object types belonged to, was ok.
    example:
    schema: scott
    view: my_view
    schema: dave
    sql: "select from scott.my.view ....."
    works well from a stored procedure, but nor if used in an object type
    create the view in schema "dave" an then
    sql: "select from my.view ....."
    works fine.
    So is someone aware of this behaviour?
    Is this a bug or a feature?
    regards
    peter

    Hello Geoff,
    here is the sample code.
    If the table my_table belongs to the same
    schema runningthe code the code runs with
    no exception.
    But if the table belongs to an other schema
    (lets say SCOTT),
    only having global synonyms and the rigths to
    select on it, the code will raise an exception "table or view does not exist"
    even if we use SCOTT.my_table in the
    select.
    create type query_o as object(
    dummy integer,
    static function get_query return
    varchar2;
    create or replace type body query_o as
    static function get_query return varchar2
    as
    query varchar2(4000) :=
    'select ' | |
    ' f.amount_month ' | |
    'into :r1 ' | |
    'from ' | |
    ' my_table f ' | |
    'where id=:p1 ';
    begin
    return query;
    end;
    end;
    create type consumer_o as object(
    amount_month number,
    member function find(p_id in integer)
    return consumer_o
    create type body consumer_o as
    member function find(p_id in integer)
    return consumer_o
    as
    l_amount number;
    begin
    execute immediate query_o.get_query()
    using out l_amount,
    in p_id;
    return consumer_o( l_amount );
    end;
    end;
    kind regards
    peetr

  • Can't see DDL of views from other schemas in Developer?

    Hi,
    I've seen elements of this problem in other threads but this problem of course has it's own twist.
    I can see other schema's objects EXCEPT VIEW DDL.
    I have given a user every role and priv that I can and they still can't see the view ddl of another schema. They can see procedures, functions etc. just not the view. I've found that if I use the user that created the users I can see the DDL of all subordinate users. Users created under that schema can not see each others views no matter what rights are given. Interestingly enough sometimes when I look to display view DDL it will flash the DDL briefly before blanking the screen. very frustrating. All the Toad fanboys are crowing about how they couldn't possibly use a tool that doesn't allow them to see other view source.
    I have also looked for settings in the preferences but could find none.
    Is this a bug? It seems like one to me.
    Any help is greatly appreciated.
    Thanks
    Mark

    We have a bug logged for this.
    Sue

  • How do I view package bodies in another schema ?

    For purposes of SOX and security/audit control, we log in under our network id's in our production environment. We have sourcecode compiled into Oracle seeded schemas ( APPS ) so that scheduled jobs are able to run with submitted from the Oracle Applications environment. We don't compile code into our personal network account areas.
    I know how to GRANT EXECUTE privs so that we can execute a package in another schema, but what I want to do is to be able to view the sourcecode in another schema. Compile into APPS but be able to see the package body from my network id schema account.
    I can't seem to find what the correct permission is anywhere. Granted I can look at DBA_SOURCE to get to it, but I want to use a tool like SQL Developer or TOAD to look at the code in a more presentable and easier to debug manner.
    Any help ?

    I did some more searching on the forum... seems its already a request... TOAD gives access to DBA_Views to resolve the issue... SQL Developer has not integrated that functionality yet, but forum entries seem to indicate that it is on the horizon.
    Thanks for responding though.
    ~Barry

  • "Read Only" open other schema's package body even have write permission

    Oracle SQL Developer 2.1 (2.1.0.63)
    I can view and modify package under my schema, but when I open other schema's package body, it show "Read Only" in status bar and can't type in code editor.
    I'm sure my connected user have write permission and it works fine in old sql developer version.
    Is there some toggle for "read only" view or some issue for new release?

    Not very helpful for you at the moment, but according to EA 2.1. Can't edit another users store procedures. this has been bugged and will hopefully get fixed soon.
    theFurryOne

  • View package body in another schema

    I have developers who want to view the code in the package body in another's schema.
    I know select text from all_source/ user_source works only for packages in your own schema.
    Granting system privelege 'create any procedure' allows the developer to view as well as update priveleges.
    As the owner of the objects what grants do I need to give to developers so that they can only view the code.

    You can grant select_catalog_role permissions to your developers. This will give your developers select access to all of the V$ views and DBA_% views. Then they can view the dba_source table to view other schema's package code..
    Regards,
    David

  • Restricted view access to other schemas 'showstopper' problem

    I'm tasked with the potential roll-out of SQL Developer across a large number of users (doing away with equivalent software in the process).
    The feedback has been very positive. However, the only real issue stopping the replacement from progressing is that we cannot view certain objects in other schemas (package bodies, triggers etc) ... i.e. we need to connect as the schema owner to view these. This is essential, otherwise everyone would need to know the application schemas password.
    Our current software has the same issue unless the following option in the Options/Startup window is activated: 'Check for access to DBA views. Otherwise, SYS.ALL_xx views will be used when listing objects'. Thereafter the issue is resolved.
    Is there any workaround (e.g. like the above) in SQL Developer?
    Many Thanks.

    Sue, thanks for your reply although I already have access to Package code via tools like SQL*Plus.
    I guess the problem being discussed here is similar to the following thread (for which you have already logged a bug). See:
    How do I view package bodies in another schema ?
    Re: How do I view package bodies in another schema ?
    On a similar issue, I note that there is a possibility that a fix will indeed be implemented in release 1.1. See:
    Package body not visible
    Re: Package body not visible
    Please advise what the current status is relating to a fix?
    Many thanks for any clarification.

  • Viewing Other Schema Objects in SqlDeveloper

    I'm running SQL Developer 1.5.1.54.40 against 10g 10.1.0.5, and am unable to view package bodies in schemas other than my own. I know there has been some discussion on this, but I'm unsure of the status. Is there a workaround, or plan to provide this functionality in the near future?

    Sue,
    There is still a problem in 1.5.0 and 1.5.1 (on win XP going against a 10.2.0.3 database) in viewing the columns of a view that is owned by another user. This worked / still works in 1.2.1.
    Regards,
    Erick
    Message was edited by:
    ESlazinski

  • Inconsistent logic for viewing others schemes objects in browser

    A while ago when we upgraded our db's to Oracle 10 we also replaced our famous green friend for Sql Developer with our entire development crew.
    Among a few other things, people were not all that happy, seeing that they lost the desired "check for access to dba views option". But as long as we could rely on a consistent view in the "other schema" in all possible views (via table, or directly in the navigator) we could defend this way of thinking for not being able to see everything.
    But unfortunately, in the latest version "1.5.1 5440", we still see inconsistent things...
    for example :
    via browser (other users schema)
    => Indexes are not visible in the indexes branch point, but they do show up on the indexes tab for the corresponding table.
    => For the same "other users scheme", Triggers do show up in the triggers branch point, but then when we check the trigger tab for the corresponding table, they are not shown
    It looks like waiting for yet another version is no option and we will be forced to retreat to the green commercial swamp on high demand of our developers...
    Ribbit :-(

    There are still a few glitches in the queries used for certain things - I cannot remember the problem you mention with indexes being posted before (although I get the same problem with indexes visible in all_indexes not appearing on other users index node), but the trigger tab problem has been discussed before (1.5PROD/EA3/EA2/EA1: Only table owners triggers show in Table's trigger tab
    theFurryOne

  • Restricting SYS user to View other schema's Tables

    Hi All,
    Oracle DB Version - 10R2
    O/S - UNIX
    Could anyone share docs or steps to prevent SYS user to view other schema's tables;
    Thanks,
    Deepak

    Dear Deepak_DBA,
    If you revoke every privilege and role from the SYS user i presume the SYS will continue to select any table from the relevant schema. SYS is a special user and not like the others.
    For instance if you want to revoke the SYSDBA and the SYSOPER from the SYS user;
    SQL> revoke sysdba, sysoper from sys;
    revoke sysdba, sysoper from sys
    ERROR at line 1:
    ORA-01998: REVOKE failed: user SYS always has SYSOPER and SYSDBAI have never seen such documentation that describes how to revoke everything or at least the SELECT ANY TABLE privilege from the SYS user.
    Please see more about the SYS and the SYSTEM users;
    SYS and SYSTEM Users;
    http://download.oracle.com/docs/cd/E11882_01/server.112/e10897/users_secure.htm#ADMQS12003
    Regards.
    Ogan

  • SQL Develeoper 1.5.5 - Synonyms in other schemas missing in tree view-BUG?

    Hi!
    I have upgraded to the latest version of SQL Developer 1.5.5. When I look in other schemas the synonyms are not displayed. Normally I am logged into an account with DBA privileges. Other objects appear to display correctly. I was not able to find this listed as a known bug. Has anyone else had this problem? Is there anything that can be done to correct it? This is a big problem for us at the moment.
    Thanks for any help, ideas, suggestions, etc.! Let me know if there is any other information I can provide.
    Dave Venus

    What do you mean by synonyms in other schemas ?
    When I look in another schema (through Other Users), the Synonyms node is filled correctly.
    Public synonyms are accessed through your own connection, in the node with the same name.
    You'll have to be more detailed as to what is failing, preferably with a reproducible example.
    K.

  • Is it possible to have source and target schema in the same DB instance ?

    Hi All,
    I'm using Oracle 11gR1.
    I have switched source locations from other server to the one with OWB.
    During deploy I get VLD-3064 and I can't deploy mapping because of many 'table or view does not exist' warnings.
    Is it possible to have source and target schemas in the same instance ??
    How to do it ?
    Regards,
    Martin

    Hi Jörg,
    Thanks for your help and quick answer.
    I'd like to clarify a little your answer :
    1. Are the any special privilages I need to set ? Currently I have only 'RESOURCE' and 'CONNECT' (I think I didn't have to add any other privs when that schema was located on other instance...)
    2. Also VLD-3064 states that : 'Owning and referenced location of this connector are on the same database instance. Unless explicitly referenced in configuration settings no generated code will use the dataabase link resulting from deployment of this connector'. Does it mean I have to put something in configuration ?
    Thanks,
    Martin

  • Oracle 10g views and procs

    We have a view with a proc imbedded within. The view's is in one schema and the proc is in another. the schema where the proc is has execute on the proc. A schema that is not the view or the proc but has select on the view is able to do so. When we try to grant select on the view to the schema that owns the proc we get an error that the proc does not have a grant option (which is not allow at our site).any ideas....

    Best resource is Backup and Recovery guide from Oracle document site.
    Backup and Recovery Advanced User's Guide
    http://download-west.oracle.com/docs/cd/B19306_01/backup.102/b14191/toc.htm

  • Is there a way to access object from other schema?

    1. Is there a way to access object from other schema
    Without using synonym/public synonym without prefixing schema owner?
    2. If you do not see any object in all_objects by same name owned by connected user or public, can there still be objects hidden from this view? for instance synonyms created by SYSTEM
    TIA for help

    Well, you missed something somewhere. If there is no
    ALTER SESSION SET CURRENT_SCHEMA=whoeverthen there must be either public synonym for the object as this shows:
    SQL> CREATE USER a identified by a;
    User created.
    SQL> GRANT CREATE SESSION to a;
    Grant succeeded.
    SQL> CREATE USER b identified by b;
    User created.
    SQL> GRANT CREATE SESSION, CREATE PROCEDURE, CREATE PUBLIC SYNONYM to b;
    Grant succeeded.
    SQL> connect b/b
    Connected.
    SQL> CREATE PACKAGE test AS
      2     PROCEDURE testit;
      3  END;
      4  /
    Package created.
    SQL> CREATE PACKAGE BODY test AS
      2  PROCEDURE testit IS
      3  BEGIN
      4     NULL;
      5  END;
      6  END;
      7  /
    Package body created.
    SQL> connect a/a
    Connected.
    SQL> desc b.test
    ERROR:
    ORA-04043: object b.test does not exist
    SQL> connect b/b
    Connected.
    SQL> GRANT EXECUTE ON test TO a;
    Grant succeeded.
    SQL> connect a/a
    Connected.
    SQL> desc b.test;
    PROCEDURE TESTIT
    SQL> desc test;
    ERROR:
    ORA-04043: object test does not exist
    SQL> connect b/b
    Connected.
    SQL> CREATE PUBLIC SYNONYM test FOR TEST;
    Synonym created.
    SQL> connect a/a
    Connected.
    SQL> desc test
    PROCEDURE TESTITAnother possibility without public synonyms is that crv had granted the other user privileges on some object, and the other user creates a private synonym for that. When crv granted privileges on a different object with the same name, the private synonym became valid again. Something like:
    SQL> connect /
    Connected.
    SQL> drop public synonym test;
    Synonym dropped.
    SQL> GRANT CREATE SYNONYM TO a;
    Grant succeeded.
    SQL> connect a/a
    Connected.
    SQL> desc test;
    ERROR:
    ORA-04043: object test does not exist
    SQL> desc b.test
    PROCEDURE TESTIT
    SQL> CREATE SYNONYM test FOR b.test;
    Synonym created.
    SQL> desc test;
    PROCEDURE TESTIT
    SQL> connect b/b
    Connected.
    SQL> REVOKE EXECUTE ON test FROM a;
    Revoke succeeded.
    SQL> connect a/a
    Connected.
    SQL> desc test;
    ERROR:
    ORA-04043: object "B"."TEST" does not exist
    SQL> desc b.test
    ERROR:
    ORA-04043: object b.test does not exist
    SQL> connect b/b
    Connected.
    SQL> DROP PACKAGE test;
    Package dropped.
    SQL> CREATE FUNCTION test (p_num IN NUMBER) RETURN NUMBER AS
      2  BEGIN
      3     RETURN p_num * 10;
      4  END;
      5  /
    Function created.
    SQL> GRANT EXECUTE ON test TO a;
    Grant succeeded.
    SQL> connect a/a
    Connected.
    SQL> desc test;
    FUNCTION test RETURNS NUMBER
    Argument Name                  Type                    In/Out Default?
    P_NUM                          NUMBER                  INSo, I would go looking for the synonyms.
    TTFN
    John

Maybe you are looking for