scott user의 자료가 user라는 TableSpace에 이미 Table의 Data뿐만 아니라
Index까지 같이 저장되어 있는 경우, 이를 jclee user로 올기고
user_i라는 인덱스 tablesapce에 인덱스만 분리할려고 할때를 생각해보자,
만약 인덱스가 몇개 없다면 지우면 users_i tablespace에 다시 만들면되나,
이경우는 아주 방대한 양의 인덱스를 옮기는 경우라고 생각을 하자...
1. scott user의 data를 export하자
oracle:/usr/local>exp scott/toger file=scottuser.dmp
2. Export받은 파일에서 index를 제외한 부분만 import
oracle:/usr/local>import system/manager file=scottuser.dmp fromuser=scott touser=jcleem indexes=n
3. indexfile option을 이용하여 인덱스 대한 script 를 생성하자
oracle:/usr/local>imp system/manager file=scottuser.dmp indexfile=scottindex.sql
4. 위의 스크립트에서 index 샹성부분의 tablespace 부분을 원하는
user_i로 만들어 주자. 그리구 @FileName으로 수행하자..
|