DBAsupport.com Forums - Powered by vBulletin
Page 1 of 2 12 LastLast
Results 1 to 10 of 12

Thread: Which table or view keep function or procedure name of any package?

  1. #1
    Join Date
    Jan 2003
    Location
    bangkok
    Posts
    7

    Which table or view keep function or procedure name of any package?

    Which table or view keep function or procedure name of any package?

    Example

    SQL> desc dbms_alert
    Element Type
    ------------ ---------
    MAXWAIT CONSTANT
    SET_DEFAULTS PROCEDURE
    REGISTER PROCEDURE
    REMOVE PROCEDURE
    REMOVEALL PROCEDURE
    WAITANY PROCEDURE
    WAITONE PROCEDURE
    SIGNAL PROCEDURE

    the name of element i want

  2. #2
    Join Date
    May 2001
    Location
    Dallas, US
    Posts
    78

    Thumbs up Try this

    select object_name from obj
    where object_type in('PROCEDURE','FUNCTION', 'PACKAGE');

    Hope this resolve your problem.

    RP Kumar
    You Can Win, if u believe Yourself

  3. #3
    Join Date
    Jan 2003
    Location
    bangkok
    Posts
    7
    thank you. Mr.Kumar_RP

    but it 's not that i want.
    which table can show subpackage to me.
    such as i describe package. it show subpackage.

  4. #4
    Join Date
    May 2001
    Location
    Dallas, US
    Posts
    78

    ?

    Hi,
    Do you want to see the script of the Package / Function / Procedure ?.
    RP Kumar
    You Can Win, if u believe Yourself

  5. #5
    Join Date
    Jan 2003
    Location
    bangkok
    Posts
    7
    thanks,
    no,i don't.
    I would like to select object_name,parameter name,data type and return datatype (if function) of package. which view can i select?

  6. #6
    Join Date
    Dec 2000
    Location
    Ljubljana, Slovenia
    Posts
    4,439
    Code:
    SELECT
      object_name AS element,
      DECODE(MIN(position), 0, 'FUNCTION', 'PROCEDURE') AS type
    FROM all_arguments
    WHERE package_name = 'DBMS_ALERT' AND owner = 'SYS'
    GROUP BY object_name;
    Jurij Modic
    ASCII a stupid question, get a stupid ANSI
    24 hours in a day .... 24 beer in a case .... coincidence?

  7. #7
    Join Date
    Sep 2001
    Location
    Düsseldorf, Germany.
    Posts
    588
    Code:
    SELECT a.object_name, argument_name, data_type,
           CASE
              WHEN (object_type = 'FUNCTION' AND in_out = 'OUT') THEN 'RETURN'
              ELSE in_out
           END CASE
    FROM user_arguments a, user_objects b
    WHERE a.object_name = b.object_name;

  8. #8
    Join Date
    May 2001
    Location
    Dallas, US
    Posts
    78

    DESCRIBE

    Hi,
    You can your details by DESCRIBE right?.

    Ex.
    My procedure name is WHO_CALLED_ME;

    SQL> describe WHO_CALLED_ME;
    PROCEDURE WHO_CALLED_ME
    Argument Name Type In/Out Default?
    ------------------------------ ----------------------- ------ --------
    OWNER VARCHAR2 OUT
    NAME VARCHAR2 OUT
    LINENO NUMBER OUT
    CALLER_T VARCHAR2 OUT


    Is it ok for you?>>
    RP Kumar
    You Can Win, if u believe Yourself

  9. #9
    Join Date
    Jan 2003
    Location
    bangkok
    Posts
    7
    thank you. mr.jmodic and mr.Sameer, that i want.
    and thank you mr.Kumar_RP for your suggest.

  10. #10
    Join Date
    Jan 2003
    Location
    bangkok
    Posts
    7
    I have more question. Can i find constant or variable?

    SQL> desc dbms_alert
    Element Type
    ------------ ---------
    MAXWAIT CONSTANT
    SET_DEFAULTS PROCEDURE
    REGISTER PROCEDURE
    REMOVE PROCEDURE
    REMOVEALL PROCEDURE
    WAITANY PROCEDURE
    WAITONE PROCEDURE
    SIGNAL PROCEDURE

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width