Thursday 12 November 2015

How to export/import a very big compressed table?

The challenge here is to transfer a very big table from one DB to another, both fast and using as little space as possible. Since the table is compressed in the source DB, we'll need to take advantage of this.
The table will stay compressed throughout the process if we'll use expdp and impdp, with the option compression=ALL.
See example below of par file for expdp:



 >cat expdp.par
userid=myuser/mypass
dumpfile=big_dir:big_table_1011.dmp
logfile=big_dir:big_table_1011.exp.log
compression=ALL


 To check expdp status:

 expdp myuser/mypass attach=SYS_EXPORT_SCHEMA_01

 Export>Status