Friday , November 22 2024

Data Export

In today’s article, I will give information about the Data Export and Export processes.

In order for us to export with the expdp tool:

We should create a database directory object in our database.

We must give read/write rights in this directory to the user who will perform the export operation.

We can learn the directories created in the database by querying the DBA_DIRECTORIES view.

We need to specify which database directory object we will use when defining the export/import operation on the command line.

If we don’t specify it, the default directory object is used. This directory is DATA_PUMP_DIR. You can find out where this directory object is on the operating system by clicking dba_directories.

EXPORT PROCESS

1. If the default directory is not used, the dump_dir directory is created under the ORACLE_HOME directory.

2. The database directory is created.

3. The user who will export is given the right to read/write on this directory. We created a user from scratch and gave the privileges.

4. Before starting the export process, either dba authorization is given to the user ”emre” or a new table is created under the ”emre” user in order to avoid any authorization problems.

We are moving forward by giving DBA authority to ”emre”.

a. Login with sysdba user.

b. Login with sysdba user.

5. Before running Export, we learn how big the export will be. (Two kinds of syntax can be used when requested to be received with SYS user)

6. We learn whether there is a place in the directory where the Export will be taken or not.

7. The size of the export and the directory where the export will be exported are compared and it is checked whether there is enough space.

If there is enough space:

8. Export is run.

WELL:

With Emre user, we export the scott.emp table to the dump_dir directory with the name emre.dmp and save the logs as emre.log in the same directory.

Loading

About Onur ARDAHANLI

Leave a Reply

Your email address will not be published. Required fields are marked *