테이블,컬럼 정의서 추출 _ 오라클 sql
--테이블 정의서 추출하기 SELECT A.TABLE_NAME, REGEXP_SUBSTR(B.COMMENTS,'[^|]+',1,1) AS CMT FROM USER_TABLES A, USER_TAB_COMMENTS B WHERE B.TABLE_NAME = A.TABLE_NAME ORDER BY A.TABLE_NAME; -- 컬럼 정의서 추출하기 SELECT TBL.TABLE_NAME , TCM.COMMENTS , TBL.TABLESPACE_NAME , TCL.COLUMN_ID , TCL.COLUMN_NAME , CCM.COMMENTS , DATA_TYPE , DATA_LENGTH /* CASE WHEN TCL.DATA_TYPE = 'VARCHAR2' OR TCL.DATA_TYPE = 'CHAR' OR TC..