Scripts: Scripts y tips
Enviado el Martes, 13 abril a las 17:08:44 por csr |
|
Como:
- Ver los Indices por Tabla
- Ver el codigo fuente de una funcion
- Ver el codigo fuente de un Procedimiento
- Ver el codigo fuente de un Package
set linesize 1000
set pagesize 60
set long 8000
Ver los Indices por Tabla
select B.INDEX_NAME,
A.COLUMN_NAME,
B.INDEX_TYPE
from user_ind_columns A, user_indexes B
where
A.index_name=b.index_name
and
a.table_name='NOMBRE DE LA TABLA'
order by B.INDEX_NAME;
Ver el codigo fuente de una funcion
select
name,
type,
line,
text
FROM USER_SOURCE
WHERE TYPE='FUNCTION'
AND NAME='NOMBRE DE LA FUNCION'
ORDER BY LINE;
Ver el codigo fuente de un Procedimiento
select
name,
type,
line,
text
FROM USER_SOURCE
WHERE TYPE='PROCEDURE'
and NAME='NOMBRE DEL PROCEDIMIENTO'
ORDER BY LINE;
Ver el codigo fuente de un Package
select
name,
type,
line,
text
FROM USER_SOURCE
WHERE TYPE IN('PACKAGE')
AND
NAME='ENTER_PACKAGE_NAME'
UNION
select
name,
type,
line,
text
FROM USER_SOURCE
WHERE TYPE IN('PACKAGE BODY')
AND
NAME='NOMBRE DEL PACKAGE';
|
| |
 |
 |
Puntuación Promedio: 3.87 votos: 32

|
|
 |
 |
|