[Oracle] Data Pump detailed tutorial (2)-expdp

Source: Internet
Author: User

[Oracle] Data Pump detailed tutorial (2)-expdp [Oracle] Data Pump detailed tutorial (1)-Overview http://www.bkjia.com/database/201307/230385.html The export mode has the following five export modes, which are mutually exclusive and cannot be used at the same time. Note: Some schemas cannot be exported, such as SYS, ORDSYS, and MDSYS. In Full mode, set Full = y (default value: n) to export the entire database. For example, [plain]> expdp user_name FULL = y DUMPFILE = expdat. dmp DIRECTORY = data_pump_dir LOGFILE = export. the log Schema mode exports one or more Schemas (the SCHEMAS parameter). By default, the current user's schema is exported. Only the DATAPUMP_EXP_FULL_DATABASE role can be used to export other Schemas. Example: [plain]> expdp hr DIRECTORY = dpump_dir1 DUMPFILE = expdat. dmp SCHEMAS = hr, sh, oe Table mode exports TABLES, partitions, and the objects they depend on. the syntax of the parameter TABLES is as follows: [plain] TABLES = [schema_name.] table_name [: partition_name] [,...] If schema_name is omitted, the table under the current user schema is exported. [plain] expdp hr TABLES = employees, jobs DUMPFILE = dpump_dir1: table. dmp NOLOGFILE = YES Tablespace mode to export one or more Tablespaces. The TABLESPACES parameter specifies the Tablespace to be exported [plain]> expdp hr DIRECTORY = dpump_dir1 DUMPFILE = tbs. dmp TABLESPACES = tbs_4, tbs_5, tbs_6 Transpotable Tablespace mode only exports Tablespace metadata. data files can be copied from the operating system layer [plain]> expdp hr DIRECTORY = dpump_dir1 DUMPFILE = tts. dmp TRANSPORT_TABLESPAC ES = tbs_1 TRANSPORT_FULL_CHECK = yes logfile = tts. the QUERY parameter used to filter data during log export parses data at the row level. Its syntax is as follows: [plain] QUERY = [schema.] [table_name:] query_clause the following example: [plain] QUERY = employees: "WHERE department_id> 10 AND salary> 10000" NOLOGFILE = yes directory = dpump_dir1 DUMPFILE = exp1.dmp parameter SAMPLE specifies the export percentage. The syntax is as follows: [plain] SAMPLE = [[schema_name.] table_name:] sample_percent: [plain]> expdp hr DIRECTORY = dpump_dir1 DUMP FILE = sample. dmp SAMPLE = 70 metadata filtering metadata parsing adopts EXCLUDE and INCLUDE parameters. Note: they are mutually exclusive. Example of EXCLUDE: [plain] expdp FULL = yes dumpfile = expfull. dmp EXCLUDE = SCHEMA: "= 'hr'"> expdp hr directory = dpump_dir1 DUMPFILE = hr_exclude.dmp EXCLUDE = VIEW, PACKAGE, function include example: [plain] SCHEMAS = hr DUMPFILE = expinclude. dmp DIRECTORY = dpump_dir1 LOGFILE = expinclude. log INCLUDE = TABLE: "IN ('employees', 'employees')" INCLUDE = procedure include = INDEX: "LIKE 'emp' % '" main parameter description CONTENT: specify whether to export only data, metadata, or all directories: Specify the database Defined DIRECTORY object DUMPFILE: Specifies the dump file name. If PARALLEL and FILESIZE are defined, it must contain the wildcard % U, for example: [plain]> expdp hr SCHEMAS = hr DIRECTORY = dpump_dir1 DUMPFILE = dpump_dir2: exp1.dmp, exp2 % U. dmp PARALLEL = 3 ESTIMATE_ONLY: If you only want to evaluate the space occupied by the dump file in advance, you can specify ESTIMATE_ONLY = yesFILESIZE: specify the maximum size of each file. HELP: if you forget the parameter, you can execute expdp help = y to display the help information JOB_NAME: Specify the job name of expdp. Generally, you do not need to specify it. The system will specify the default unique JOB_NAME. You can view the Job name logfile in the LOGFILE: specify the log file name. The default value is export. logPARALLEL: The default value is 1. Parallelism is used. For a relatively large export, we recommend that you increase the degree of parallelism, but the maximum number of CPUs cannot exceed 2 times. PARFILE: Specify the parameter file name REMAP_DATA: assume that you export sensitive information from the production database to the test database. To prevent this sensitive information from being leaked, you can modify the information during export to protect the sensitive information. REUSE_DUMPFILE: sets whether to reuse existing DUMPFILE

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.