프로그래밍/Oracle

오라클 테이블 정보 보기

GOHA 2015. 4. 23. 17:32
728x90

<오라클 테이블 정보 보기>


-- 전체 테이블 정보 보기

select * from all_tables ;

-- 특정 유정의 테이블 정보

select * from all_tables where owner = '유저아이디'

-- 테이블 comments 정보

select * from user_tab_comments

-- 테이블 컬럼 comments 정보

select * from user_col_comments 

-- 컬럼 정보(컬럼 타입, 길이, null 허용 여부 등)

select * from user_tab_columns

-- 해당 유저의 모든 컬럼 제약 사항 보기

select * from user_constraints

-- 해당 유저가 조회 가능한 데이터베이스의 모든 제약 조건 조회

select * from dba_constraint

-- 해당 유저가 조회 가능한 모든 제약 조건 조회

select * from all_constraint

select * from all_tables a1 left join user_tab_columns a2 on a1.table_name=a2.table_name where owner='유저아이디';

728x90