C:>exp test/test@orcl file='c:bakt.dmp' tables=t2
Export: Release 10.2.0.1.0 - Production on 星期四 9月 3 19:16:44 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
连接到: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
已导出 ZHS16GBK 字符集和 AL16UTF16 NCHAR 字符集
即将导出指定的表通过常规路径...
. . 正在导出表 T2导出了 759316 行
成功终止导出, 没有出现警告。
C:>
--=========================
--要导入的数据占23m
SQL> select segment_name,bytes/1024/1024 from dba_segments where segment_name='T
2';
SEGMENT_NA BYTES/1024/1024
---------- ---------------
T2 23
--users表空间对应的dataifle 9是4m并且无法自动扩展
SQL> select file_id,file_name,tablespace_name,bytes/1024/1024 m ,autoextensible
from dba_data_files;
FILE_ID FILE_NAME TABLESPACE M AUT
---------- ------------------------------ ---------- ---------- ---
1 C:TEMPSYSTEM01.DBF SYSTEM 300 YES
9 C:TEMPUSERS.DBF USERS 4 NO
6 C:TEMPUNDOTBS02.DBF UNDOTBS2 10 NO
5 C:TEMPTEST.DBF TEST 55 YES
3 C:TEMPSYSAUX01.DBF SYSAUX 120 YES
SQL> alter table t2 rename to t2_bak;
表已更改。
SQL> create table t2 tablespace users as select * from t2_bak where 1=2;
表已创建。
SQL>
--====================================
C:>imp test/test@orcl file='c:bakt.dmp' full=y ignore=y
Import: Release 10.2.0.1.0 - Production on 星期四 9月 3 19:22:09 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
连接到: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
经由常规路径由 EXPORT:V10.02.01 创建的导出文件
已经完成 ZHS16GBK 字符集和 AL16UTF16 NCHAR 字符集中的导入
. 正在将 TEST 的对象导入到 TEST
. 正在将 TEST 的对象导入到 TEST
. . 正在导入表 "T2"
IMP-00058: 遇到 ORACLE 错误 1653
ORA-01653: 表 TEST.T2 无法通过 128 (在表空间 USERS 中) 扩展
IMP-00028: 上一个表的部分导入已回退: 回退 99149 行
成功终止导入, 但出现警告。
C:>
--提示"表 TEST.T2 无法通过 128 (在表空间 USERS 中) 扩展...回退 99149 行",下面查询也
验证了没有数据导入
--========================================
SQL> select count(*) from t2;
COUNT(*)
----------
0
SQL>
--========================================
C:>imp test/test@orcl file='c:bakt.dmp' full=y ignore=y buffer=8192 commit=y
Import: Release 10.2.0.1.0 - Production on 星期四 9月 3 19:24:51 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
连接到: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
经由常规路径由 EXPORT:V10.02.01 创建的导出文件
已经完成 ZHS16GBK 字符集和 AL16UTF16 NCHAR 字符集中的导入
. 正在将 TEST 的对象导入到 TEST
. 正在将 TEST 的对象导入到 TEST
. . 正在导入表 "T2"
IMP-00058: 遇到 ORACLE 错误 1653
ORA-01653: 表 TEST.T2 无法通过 128 (在表空间 USERS 中) 扩展
IMP-00018: 上一个表的部分导入已完成: 导入了 99149 行
成功终止导入, 但出现警告。
C:>
--在导入时使用了commit=y发现数据导入了,简单的验证了doc上提到的如果
设置了commit=y则导入是按照buffer提交,否则按table提交
--===========================
SQL> select count(*) from t2;
COUNT(*)
----------
99149
SQL> select segment_name,bytes/1024/1024 from dba_segments where segment_name='T
2';
SEGMENT_NA BYTES/1024/1024
---------- ---------------
T2 3
SQL>
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/19602/viewspace-1026617/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/19602/viewspace-1026617/