Oracle(96)
-
운영중인 자동관리 undo tablespace 가 깨졌을 시
pfile의 undo_management 를 MANUAL로 수정한 후 pfil로 open 한다. SQL> startup '$ORACLE_HOME/dbs/init$ORACLE_SID.ora; SQL> drop tablespace undotbs1 including contents and datafiles cascade constraints; 재생성한다.SQL> create undo tablespace undotbs1 datafile '/data1/oradata/undotbs01.dbf' size 10m 2 autoextend on next 5m maxsize 50m; SQL> shutdown immediate; pfile의 undo_management 를 다시 AUTO로 수정한 후 startup 한다.
2012.05.09 -
ORA-02429: 고유/기본 키 적용을 위한 인덱스를 삭제할 수 없습니다.
PK 제거 후 삭제 해야 함. ALTER TABLE table_name DROP PRIMARY KEY;
2012.04.26 -
Datafile resize에 대한 오해(?)
용량이 부족할 때 데이터 파일을 추가 해주는 형식으로 주로 하였기에, resize 할 때 문제를 생각해 보지 않았다. autoextensible 되고 있는 데이터 파일을 resize를 하면 resize 한 만큼의 용량으로 자동 증가가 되는 줄 알았다. 하지만 아래 결과를 보게 된다면 생각이 달라질 것이다. 테이블 스페이스를 생성하고 상태 변경까지 각각의 size를 확인해 볼 것이다. 1. 테이블 스페이스 생성 ### create tablespace tbs_auto ### datafile '/oracle/oradata/orcl/Disk3/tbs_auto.bdf' size 1m ### autoextend on next 8k maxsize 3m; TABLESPACE AUT current(MB) Max exte..
2012.01.20 -
sh 계정 생성
$ORACLE_HOME/demo/sales_history/sql_main.sql 실행. 해당파일이 생성되지 않았으면 개별적으로 다운받아서 실행. 파일 용량이 큰 관계로 올리지 못하였다. 대략 17M 정도되며, 분할하여 올리려고 하였지만 회사 컴퓨터라 분할 할 여유가 되질 못하였다. specify password for SH as parameter 1: --> sh 계정에 대한 password 지정 Enter value for 1: ****** specify default tablespace for SH as parameter 2: --> default tablespace 지정 Enter value for 2: users specify temporary tablespace for SH as paramete..
2011.12.26 -
Diagnostics) Oracle10g DB 접속 안될때 sqlplus 에서 SYSTEMSTATE DUMP 받기
http://kr.forums.oracle.com/forums/thread.jspa?threadID=619271&tstart=0 ========================================================================= PURPOSE -------------------------------------------------------------------------------- Oracle10g 이상에서는 HANG 발생으로 DB 접속 안될때 OS 디버거 사용안하고도 sqlplus -prelim 옵션으로 간단하게 SYSTEMSTATE DUMP 를 받을 수 있다. EXPLANATIONS ----------------------------------------------..
2011.12.22 -
ALL_COL_COMMENTS
http://docs.oracle.com/cd/B28359_01/server.111/b28320/statviews_1036.htm ALL_COL_COMMENTSALL_COL_COMMENTS displays comments on the columns of the tables and views accessible to the current user. Related Views DBA_COL_COMMENTS displays comments on the columns of all tables and views in the database. USER_COL_COMMENTS displays comments on the columns of the tables and views owned by the current us..
2011.12.22