'스키마'에 해당되는 글 1건

  1. 2006.09.27 [Oracle - Query] Schema by pino93

 

1.테이블
select object_name from user_objects where object_type = 'TABLE';


2.
select object_name from user_objects where object_type = 'VIEW';


3.시퀀스
select object_name from user_objects where object_type = 'SEQUENCE';


4.인덱스
select object_name from user_objects where object_type = 'INDEX';


5.프록시져
select object_name from USER_PROCEDURES;


6.트리거
select trigger_name from user_triggers;


7.패키지
select object_name from user_objects where object_type = 'PACKAGE';


8.
select GRANTED_ROLE from user_role_privs;


9.테이블스패이스
select DEFAULT_TABLESPACE, TEMPORARY_TABLESPACE from user_users;


10.시노늄
select * from user_synonyms where TABLE_OWNER = user;


11.함수
select object_name from user_objects where object_type = 'FUNCTION';


부가정보뷰에서정보를보여주기위한쿼리..


1.테이블
select TABLE_NAME, COLUMN_NAME, DATA_TYPE, DATA_LENGTH, NULLABLE from USER_TAB_COLUMNS where table_name = '%s';


2.
select VIEW_NAME, TEXT_LENGTH, VIEW_TYPE_OWNER from USER_VIEWS where VIEW_NAME = '%s';


3.시퀀스
select SEQUENCE_NAME, MIN_VALUE, MAX_VALUE, INCREMENT_BY, CYCLE_FLAG, ORDER_FLAG, CACHE_SIZE, LAST_NUMBER from USER_SEQUENCES where SEQUENCE_NAME = '%s';


4.인덱스
select INDEX_NAME, TABLE_NAME, COLUMN_NAME, COLUMN_POSITION, DESCEND from user_ind_columns where INDEX_NAME = '%s';


5.프로시져
select PROCEDURE_NAME, AGGREGATE, PIPELINED, PARALLEL, INTERFACE, DETERMINISTIC, AUTHID from USER_PROCEDURES where PROCEDURE_NAME = '%s';


6.트리거
select TRIGGER_NAME, TRIGGER_TYPE, TRIGGERING_EVENT, TABLE_OWNER, TABLE_NAME, COLUMN_NAME from USER_TRIGGERS where TRIGGER_NAME = '%s'


7.
select GRANTED_ROLE, ADMIN_OPTION, DEFAULT_ROLE, OS_GRANTED from user_role_privs;


8.시노늄
select SYNONYM_NAME, TABLE_OWNER, TABLE_NAME, DB_LINK from USER_SYNONYMS where SYNONYM_NAME = '%s'

 

'DB/ETL > Oracle' 카테고리의 다른 글

[ORACLE - Hint] 병렬처리(APPEND)  (0) 2007.10.23
[Oracle] ROWID  (1) 2007.04.07
[Oracle - Query] Schema  (0) 2006.09.27
[Oracle - Query] 주차구하기  (0) 2006.09.26
[Oracle - Query] 컬럼명 및 TYPE 가져오기  (0) 2006.09.13
[Oracle - Hint] Optimizer Mode Setting 방법  (0) 2006.08.31
Posted by pino93