2005. 12. 22. 15:40
--COMMENTS
SELECT B.COLUMN_ID, B.COLUMN_NAME, A.COMMENTS,
decode(b.data_type,'FLOAT',b.data_type,'DATE',b.data_type,B.DATA_TYPE||'('||decode(b.data_precision,null,B.DATA_LENGTH,b.data_precision)||')') TYPES,
DECODE(B.NULLABLE,'Y','Y',B.NULLABLE) ISNULL
FROM ALL_COL_COMMENTS A,
--(SELECT * FROM cols WHERE TABLE_NAME = 'TB_MAILHOSTING') B
(SELECT * FROM all_tab_columns WHERE TABLE_NAME = :vTable_Name and owner='BILL') B
WHERE A.TABLE_NAME(+) = :vTable_Name
AND A.COLUMN_NAME(+) = B.COLUMN_NAME
AND A.owner='BILL'
ORDER BY B.COLUMN_ID
SELECT B.COLUMN_ID, B.COLUMN_NAME, A.COMMENTS,
decode(b.data_type,'FLOAT',b.data_type,'DATE',b.data_type,B.DATA_TYPE||'('||decode(b.data_precision,null,B.DATA_LENGTH,b.data_precision)||')') TYPES,
DECODE(B.NULLABLE,'Y','Y',B.NULLABLE) ISNULL
FROM ALL_COL_COMMENTS A,
--(SELECT * FROM cols WHERE TABLE_NAME = 'TB_MAILHOSTING') B
(SELECT * FROM all_tab_columns WHERE TABLE_NAME = :vTable_Name and owner='BILL') B
WHERE A.TABLE_NAME(+) = :vTable_Name
AND A.COLUMN_NAME(+) = B.COLUMN_NAME
AND A.owner='BILL'
ORDER BY B.COLUMN_ID
'ORACLE' 카테고리의 다른 글
strncmp (0) | 2006.02.03 |
---|---|
& 기호 이용하기 (1) | 2006.01.20 |
sqlplus에서 한줄로 조회하기 (2) | 2005.12.19 |
날자함수의 버그인가? (0) | 2005.12.08 |
자바풀 사이즈를 조정하려면:오라클 파라미터 java_pool_size (0) | 2005.12.08 |