With this Loader command, you can control the unloading of database tables.
<tableextract_statement>
::=
TABLEEXTRACT <part_spec
> [<configurationstream_spec
>] <dataoutstream_spec
> [<packagestream_spec
>]
[<restart>]
You can also use the keywords EXTRACT DATA instead of the keyword DATAEXTRACT.
If you
are using TABLEEXTRACT TABLE, the source table must exist in the database
instance.
The command
TABLEEXTRACT ALL can only be executed by the database system
administrator (SYSDBA user).
· You can unload the application data (including LONG values) of the specified database tables to data streams. The format of the data stream must be PAGES in each case.
· You can unload the application data (including LONG values) and the database catalog definitions of the specified database tables to data streams. The format of the data stream must be RECORDS in each case.
You cannot change the data streams.
Tables are write-protected while they are unloaded to the data stream.
·
TABLEEXTRACT
ALL
The data stream <dataoutstream_spec> contains the application data
of all tables.
·
TABLEEXTRACT
USER
The data stream <dataoutstream_spec> contains the application data
of the tables that belong to the specified user.
·
TABLEEXTRACT
TABLE
The specified table is a base table. The user is the owner of this
table.
The data stream
<dataoutstream_spec> contains the application data
of the specified table.
The data streams <dataoutstream_spec> are created during unloading.
When it processes the commands TABLEEXTRACT ALL and TABLEEXTRACT USER, the Loader creates one or more data streams (depending on the size of the tables it is unloading), each of which can contain the application data from one or more tables. The Loader specifies the maximum size of a single data stream as 1 GB.
The media names for the data streams are created using the name specified in the command, by adding a four digit extension of the format 0001 to the name. The maximum number of media for each TABLEEXTRACT is therefore set at 9999.
The system table TRANSFORMATIONMODEL and other system tables are filled.
· Unless you specify the data stream <configurationstream_spec>, all specified tables are unloaded.
·
By specifying
a data stream <configurationstream_spec>, you can exclude the
application data of selected tables from the unload process<dataoutstream_spec>. The tables must be identified in the data stream by
the specification of their owner and the table name.
The information
about which tables are not unloaded is stored in the system
tables. You can display this information by displaying the
system table TRANSFORMATIONPACKAGES. The
tables excluded from the unload of the application data have the value TRUE in
the column EXCLUDE.
· When you specify a data stream <packagestream_spec>, all entries of the table TRANSFORMATIONPACKAGES are unloaded to this data stream. You are recommended to use this option to create a log of the unload process.
· If you do not specify the data stream <packagestream_spec>, the system table TRANSFORMATIONPACKAGES is not unloaded.
The specified tables are unloaded to the data streams <dataoutstream_spec>.
If necessary, all entries of the table TRANSFORMATIONPACKAGES are unloaded to the data stream <packagestream_spec>.
You can reload the tables using the corresponding TABLELOAD command.
The unload process cannot be successfully completed. In this case, the Loader logs the cause of the error in the log file.
The values PACKAGEGUID and CLIENTNODE are also written to the log file. The PACKAGEGUID is required if you want to restart the unload process.