PAGES and RECORDS are possible formats for a data stream.
You can these two formats in the commands: EXPORT DB, EXPORT USER and EXPORT SCHEMA or IMPORT DB, IMPORT USER and IMPORT SCHEMA. Loader assumes that the data streams for these commands are in PAGES format. You therefore do not have to specify format PAGES. If you do not want to use PAGES format, you have to explicitly specify RECORDS format in a command for exporting (or importing). You can also use PAGES and RECORDS format in the EXPORT TABLE and IMPORT TABLE commands. However, you always have to explicitly specify PAGES or RECORDS format in an EXPORT TABLE or IMPORT TABLE command because the default value is CSV.
PAGES and RECORDS formats are binary formats specific to Loader. Users should not alter the data streams manually. The data cannot be read in this format. You can specify the format you require in commands for exporting and importing using the syntax rules for data format table_dataformat_spec and data stream outstream_pages_spec, instream_pages_spec, outstream_records_spec, import_records_spec.
The data is stored in the data stream as pages.
EXPORT TABLE: Loader generates a single data stream.
EXPORT DB, EXPORT USER, EXPORT SCHEMA: Loader generates at least two data streams. Depending on the data volume being exported, more than two data streams can be generated. The names of the data streams are mapped as follows: 4 digits are attached to each name, starting with 0000. The maximum number of data streams is therefore fixed at 9999.
The data stream with the sequence 0000 is known as the mapping file. Loader saves information in this file that is used to manage the data streams during import. The file can be read, but should not be changed.
Data streams with the sequence 0001 and higher contain the actual data; that is, the application data from the tables is saved in pages.
The data stream(s) with the application data contain(s) all the application data of a table, including any LOB values. The PAGES format makes it possible to export or import very quickly using special commands that are only available to Loader. No log entries are written during import and the table is then write-protected. If table data was imported in PAGES format, it can only be changed if the data was backed up incrementally or completely.
You cannot make any other entries for the columns when you export or import a table in PAGES format. All the relevant information is already contained in the data streams. You cannot import the data into a table if either of the following situations occurs:
The binary structure of the table is different from the structure of the source table
The table you want to import the data into already contains data
In both cases, Loader terminates the IMPORT with an error.
The data is stored in a binary format specific to Loader, not unlike a database record in the data stream.
EXPORT TABLE: Loader generates a single data stream.
EXPORT DB, EXPORT USER, EXPORT SCHEMA: Loader generates two data streams. The names of the data streams are mapped as follows; 4 digits are attached to each name, either 0000 or 0001.
The data stream with the sequence 0000 is known as the mapping file. Loader saves information in this file that is used to manage the data streams. The file can be read but should not be changed.
Data streams with the sequence 0001 contain the actual data, that is the application data from the tables is saved consecutively.
The data stream with the application data contains all the application data of a table, including any LOB values. If RECORDS format is used, Loader uses normal mass SELECT and mass INSERT statements, which it generates itself.
Example
EXPORT USER DATA OUTSTREAM 'mona_pages.data'
Export the application data from database user MONA to the mona_pages.data data stream in PAGES format (default value).
Mapping file mona_pages.data0000
"HOTEL","CITY","1","?","?","?","?","mona.pages0001","FILE","?","PAGES","ASCII","0","1024","0","66560","0","0""HOTEL","CUSTOMER","2","?","?","?","?","mona.pages0001","FILE","?","PAGES","ASCII","0","66560","0","132096","0","0""HOTEL","HOTEL","3","?","?","?","?","mona.pages0001","FILE","?","PAGES","ASCII","0","132096","0","214016","0","0""HOTEL","ROOM","4","?","?","?","?","mona.pages0001","FILE","?","PAGES","ASCII","0","214016","0","279552","0","0""HOTEL","EMPLOYEE","5","?","?","?","?","mona.pages0001","FILE","?","PAGES","ASCII","0","279552","0","345088","0","0""HOTEL","RESERVATION","6","?","?","?","?","mona.pages0001","FILE","?","PAGES","ASCII","0","345088","0","410624","0","0"
Example
EXPORT USER DATA OUTSTREAM 'mona_records.data' RECORDS
Export the application data from database user MONA to the mona_records.data data stream in RECORDS format.
Mapping file mona_records.data0000
"HOTEL","CITY","1","?","?","?","?","mona.records0001","FILE","?","RECORDS","ASCII","0","0","0","2610","0","1586""HOTEL","CUSTOMER","2","?","?","?","?","mona.records0001","FILE","?","RECORDS","ASCII","0","2610","0","5463","0","4439""HOTEL","HOTEL","3","?","?","?","?","mona.records0001","FILE","?","RECORDS","ASCII","0","5463","0","10240","0","9216""HOTEL","ROOM","4","?","?","?","?","mona.records0001","FILE","?","RECORDS","ASCII","0","10240","0","13199","0","12175""HOTEL","EMPLOYEE","5","?","?","?","?","mona.records0001","FILE","?","RECORDS","ASCII","0","13199","0","15552","0","14528""HOTEL","RESERVATION","6","?","?","?","?","mona.records0001","FILE","?","RECORDS","ASCII","0","15552","0","18033","0","17009"
Database Administration, Backing Up Data