Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use exp/expdp imp/impdp in database

2025-01-21 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

Editor to share with you how to use exp/expdp imp/impdp in the database, I believe most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!

1. Export 2 tables with the first nine rows of data

Oracle@SLES-10-01 where rownum ~ > exp ICDCC/* file=/home/oracle/icdcc3.dmp tables=T_UCP_STAFFEXTENDINFO,T_CHF_AGENTCFG_20130911BAK query=\ "where rownum\"

< 10\" ..... About to export specified tables via Conventional Path ... . . exporting table T_UCP_STAFFEXTENDINFO 9 rows exported EXP-00091: Exporting questionable statistics. EXP-00091: Exporting questionable statistics. . . exporting table T_CHF_AGENTCFG_20130911BAK 9 rows exported EXP-00091: Exporting questionable statistics. Export terminated successfully with warnings. //需要说明的是,EXP-00091这个error对所生成的dump文件没有影响,生成的dump文件还可以正常imp 2.导入之后查看验证 oracle@SLES-10-01:~>

Imp ICDCC/* file=/home/oracle/icdcc3.dmp FULL=Y

SQL > select count (*) from T_CHF_AGENTCFG_20130911BAK

COUNT (*)

-

nine

SQL > select count (*) from T_UCP_STAFFEXTENDINFO

COUNT (*)

-

nine

3. Create a test table

SQL > create table test1 (x int)

Table created.

SQL > create table test2 (x int)

Table created.

SQL > select * from tab

TNAME TABTYPE CLUSTERID

TEST1 TABLE

TEST2 TABLE

T_CHF_AGENTCFG_20130911BAK TABLE

T_UCP_STAFFEXTENDINFO TABLE

4. Export tables and exclude N unwanted tables

Oracle@SLES-10-01in ~ > expdp ICDCC/* directory=hzh file=icdcc4.dmp EXCLUDE=TABLE:\ "in\ (\ 'T_CHF_AGENTCFG_20130911BAK\',\ 'T_UCP_STAFFEXTENDINFO\',\ 'TEST1\')\"

/ / excluding the table, this statement will export a series of stored procedure functions if they exist, and will not be verified.

5. Verify after import

Oracle@SLES-10-01 ~ > impdp ICDCC/* directory=hzh file=icdcc4.dmp

SQL > select * from tab

TNAME TABTYPE CLUSTERID

TEST2 TABLE

The above is all the contents of the article "how to use exp/expdp imp/impdp in the database". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report