Entering content frame

Function documentation Importing: Commands Locate the document in the library structure

Use

The Loader can process a range of commands and SQL statements, including Loader-specific commands for importing data.

Prerequisites

Creating a Database Session: Commands

Syntax

<import_command> ::= IMPORT <part_spec>
  [<duplicates_clause>]
  [<configuration_instream_spec>]
  (<catalog_instream_spec> <data_instream_spec>
  |<catalog_instream_spec>
  |<data_instream_spec>)
  [<package_outstream_spec>]
  [<restart>]

Features

The Loader’s range of commands makes it possible to import, with increasing granularity, a complete database, the objects of a user, the objects of a schema, individual tables or a set of columns of a table.

You can use the syntax rule

<part_spec> ::= DB | USER | SCHEMA <schema_name> | TABLE <table_name>

to specify the required granularity. That is, you can specify whether you want to import all data, the data of a user, schema or a table.

You can export a set of columns of a table using the IMPORT COLUMNS or IMPORT TABLE command. You can use UPDATE COLUMNS to update columns.

Under consideration of the granularity, the import commands can be classified as follows:

What is to be imported?

Loader command (abbreviated)

 

<part_spec> ::= DB

Entire database catalog and all application data

IMPORT DB
  CATALOG <instream_spec>
  DATA <instream_spec>
  PACKAGE <outstream_spec>

Entire database catalog

IMPORT DB
  CATALOG <instream_spec>
  PACKAGE <outstream_spec>

All application data of the database

IMPORT DB
  DATA <instream_spec>
  PACKAGE <outstream_spec>

 

See also: IMPORT DB Commands

 

<part_spec> ::= USER

Database catalog and all application data of a user

IMPORT USER
  CATALOG <instream_spec>
  DATA <instream_spec>
  PACKAGE <outstream_spec>

Database catalog of a user

IMPORT USER
  CATALOG <instream_spec>
  PACKAGE <outstream_spec>

All application data of a user

IMPORT USER
  DATA <instream_spec>
  PACKAGE <outstream_spec>

 

See also: IMPORT USER Commands

 

<part_spec> ::= SCHEMA <schema_name>

Database catalog and all the application data of a schema

IMPORT SCHEMA <schema_name>
  CATALOG <instream_spec>
  DATA <instream_spec>
  PACKAGE <outstream_spec>

Database catalog of a schema

IMPORT SCHEMA <schema_name>
  CATALOG <instream_spec>
  PACKAGE <outstream_spec>

All application data of a schema

IMPORT SCHEMA <schema_name>
  DATA <imstream_spec>
  PACKAGE <outstream_spec>

 

See also: IMPORT SCHEMA Commands

 

<part_spec> ::= TABLE <table_name>

Database catalog and all the application data of a table

IMPORT TABLE <table_name>
  CATALOG <instream_spec>
  DATA <instream_spec>
  PACKAGE <outstream_spec>

Database catalog of a table

IMPORT TABLE <table_name>
  CATALOG <instream_spec>
  PACKAGE <outstream_spec>

All application data of a table

IMPORT TABLE <table_name>
  DATA <instream_spec>
  PACKAGE <outstream_spec>

 

See also: IMPORT TABLE Commands

Other Commands

Import set of qualified columns of a table

IMPORT TABLE <table_spec>
  
<load_column_spec>...
  <data_instream_spec>

See also: IMPORT TABLE Commands

 

IMPORT COLUMNS TABLE <table_spec>
  <load_column_spec>...
  <data_instream_spec>

See also: IMPORT COLUMNS Commands

Change set of qualified columns of a table

UPDATE COLUMNS TABLE <table_spec>
    <simple_column_spec>
SET <load_column_spec>
    <instream_spec>

See also: UPDATE COLUMNS Commands

See also:

Exporting and Importing: Syntax Elements

Exporting: Commands

Exporting and Importing LONG Values

Exporting and Importing using Third-Party Backup Tools

Syntax Rules: Overview

 

Leaving content frame