Oracle PL/SQL/System Tables Views/dba source

Материал из SQL эксперт
Версия от 10:01, 26 мая 2010; Admin (обсуждение | вклад) (1 версия)
(разн.) ← Предыдущая | Текущая версия (разн.) | Следующая → (разн.)
Перейти к: навигация, поиск

Query dba_source table

 
SQL> 
SQL>
SQL>
SQL> set feedback on
SQL> set heading off
SQL> set termout off
SQL> set linesize 1000
SQL> set trimspool on
SQL> set verify off
SQL>
SQL> select decode( type||"-"||to_char(line,"fm99999"),
  2                 "PACKAGE BODY-1", "/"||chr(10),
  3                  null) ||
  4         decode(line,1,"create or replace ", "" ) ||
  5         text text
  6    from dba_source
  7   where rownum < 50;
create or replace TYPE     re$nv_list
                                                                       AS OBJECT
( actx_list sys.re$nv_array,
  MEMBER PROCEDURE add_pair(name IN varchar2, value IN sys.anydata),
  MEMBER PROCEDURE remove_pair(name IN varchar2),
  MEMBER FUNCTION  get_value(name IN varchar2) RETURN sys.anydata,
  MEMBER FUNCTION  get_all_names RETURN sys.re$name_array
)
create or replace package STANDARD AUTHID CURRENT_USER is              -- careful on this line; SED edit occurs!
  /********** Types and subtypes, do not reorder **********/
  type BOOLEAN is (FALSE, TRUE);
  type DATE is DATE_BASE;
  type NUMBER is NUMBER_BASE;
  subtype FLOAT is NUMBER; -- NUMBER(126)
  subtype REAL is FLOAT; -- FLOAT(63)
  subtype "DOUBLE PRECISION" is FLOAT;
  subtype INTEGER is NUMBER(38,0);
  subtype INT is INTEGER;
  subtype SMALLINT is NUMBER(38,0);
  subtype DECIMAL is NUMBER(38,0);
  subtype NUMERIC is DECIMAL;
  subtype DEC is DECIMAL;

  subtype BINARY_INTEGER is INTEGER range "-2147483647"..2147483647;
  subtype NATURAL is BINARY_INTEGER range 0..2147483647;
  subtype NATURALN is NATURAL not null;
  subtype POSITIVE is BINARY_INTEGER range 1..2147483647;
  subtype POSITIVEN is POSITIVE not null;
  subtype SIGNTYPE is BINARY_INTEGER range "-1"..1;  -- for SIGN functions
  type VARCHAR2 is NEW CHAR_BASE;
  subtype VARCHAR is VARCHAR2;
  subtype STRING is VARCHAR2;
  subtype LONG is VARCHAR2(32760);
  subtype RAW is VARCHAR2;
  subtype "LONG RAW" is RAW(32760);
  subtype ROWID is VARCHAR2(256);
  -- Ansi fixed-length char
  -- Define synonyms for CHAR and CHARN.
  subtype CHAR is VARCHAR2;
49 rows selected.
SQL>
SQL> set feedback on
SQL> set heading on
SQL> set termout on
SQL> set linesize 100
SQL>
SQL> --