HiRDB Dataextractor Version 8

Description, User's Guide and Operator's Guide

3020-6-362(E)

Contents

Notices

Preface

1. Overview of HiRDB Dataextractor

1.1 Features

1.2 Functions

2. HiRDB Dataextractor Environment Setup

2.1 Software configuration

2.2 Environment setup procedure

2.2.1 Environment setup procedure

2.2.2 Installing HiRDB Dataextractor

2.2.3 Specifying environment variables

2.2.4 Files required in order to use HiRDB Dataextractor

2.3 Preparations before execution

2.3.1 Preparing tables

2.3.2 Preparing for data transfer

3. Extracting and Importing Data and Creating Files

3.1 Extracting data (HiRDB)

3.1.1 Extracting selected data

3.1.2 Adding columns to extracted data

3.1.3 Converting the data type of extracted data

3.1.4 Converting the character codes of extracted data

3.2 Extracting data (ORACLE)

3.2.1 Extracting selected data

3.2.2 Adding columns to extracted data

3.2.3 Converting the data type of extracted data

3.2.4 Converting the character codes of extracted data

3.3 Importing data

3.4 Creating files

4. Extracting Data from HiRDB and Importing It into HiRDB

4.1 Extraction and import conventions

4.1.1 Conventions for extraction

4.1.2 Conventions for import

4.2 Command

4.2.1 Command format

4.2.2 xtrep command

4.2.3 Additional data extraction and import functions

4.2.4 Contents of files specified with the xtrep command

4.3 Formats of output listings

4.4 Examples

5. Extracting Data from ORACLE and Importing It into HiRDB

5.1 Command

5.1.1 Command format

5.1.2 xtrepO command

5.1.3 Additional data extraction and import functions

5.1.4 Contents of files specified with the xtrepO command

5.2 Formats of output listings

5.3 Examples

6. Operation

6.1 Operating procedure

6.2 Starting and terminating HiRDB Dataextractor

6.2.1 Starting and terminating HiRDB Dataextractor when using TCP/IP

6.2.2 Starting and terminating HiRDB Dataextractor when using OSI

7. Error Handling Procedures

7.1 HiRDB Dataextractor error handling procedures

8. Messages

8.1 Overview of messages

8.1.1 Message format

8.1.2 Message explanatory format

8.1.3 Message output destinations

8.2 Details of messages

Appendixes

A. Memory and File Requirements

B. Functional Differences with Windows

C. Functional Differences with Solaris

D. Functional Differences with Linux

E. Functional Differences with AIX

Index

[Trademarks]

All rights reserved. Copyright (C) 2007, Hitachi, Ltd.

Notices

Relevant program products

List of program products:
For the Windows 2000, Windows XP Professional, Windows XP x64 Edition, Windows Server 2003, Windows Server 2003 x64 Edition, Windows Server 2003 R2, and Windows Server 2003 R2 x64 Edition operating systems:

P-2462-1J87 HiRDB Dataextractor Version 8 08-00

For the Windows Server 2003 (IPF) operating system:

P-2862-1J87 HiRDB Dataextractor Version 8 08-00

For the Windows Server 2003 x64 Edition and Windows XP x64 Edition operating systems:

P-2962-1J87 HiRDB Dataextractor Version 8 08-00

Trademarks

AIX is a registered trademark of the International Business Machines Corp. in the U.S.
HP-UX is a product name of Hewlett-Packard Company.
Itanium is a registered trademark of Intel Corporation or its subsidiaries in the United States and other countries.
Linux is a registered trademark of Linus Torvalds.
Microsoft is a registered trademark of Microsoft Corp. in the U.S. and other countries.
ORACLE is a registered trademark of Oracle Corporation.
Solaris is a trademark or registered trademark of Sun Microsystems, Inc. in the United States and other countries.
Sun Microsystems is a trademark or registered trademark of Sun Microsystems, Inc. in the United States and other countries.
The right to use the trademark DCE in Japan is sub-licensed from OSF.
UNIX is a registered trademark of The Open Group in the United States and other countries.
Visual C++ is a registered trademark of Microsoft Corp. in the U.S. and other countries.
Windows is a registered trademark of Microsoft Corp. in the U.S. and other countries.
Windows Server is a registered trademark of Microsoft Corp. in the U.S. and other countries.
X/Open is a registered trademark of X/Open Company Limited in the U.K. and other countries.
Other products and company names mentioned in this document may be the trademarks of their respective owners. Throughout this document Hitachi has attempted to distinguish trademarks from descriptive terms by writing the name with the capitalization used by the manufacturer, or by writing the name with initial capital letters. Hitachi cannot attest to the accuracy of this information. Use of a trademark in this document should not be regarded as affecting the validity of the trademark.

Restrictions

Information in this document is subject to change without notice and does not represent a commitment on the part of Hitachi. The software described in this manual is furnished according to a license agreement with Hitachi. The license agreement contains all of the terms and conditions governing your use of the software and documentation, including all warranty rights, limitations of liability, and disclaimers of warranty.
Material contained in this document may describe Hitachi products not available or features not available in your country.
No part of this material may be reproduced in any form or by any means without permission in writing from the publisher.
Printed in Japan.

Edition history

Edition 1 (3020-6-362(E)): March 2007

Copyright

All rights reserved. Copyright (C) 2007, Hitachi, Ltd.

Preface

This manual provides an overview of using HiRDB Dataextractor to link data between HiRDB and other database systems. It also explains the environment setup that is required in order to use HiRDB Dataextractor.

Note that the English version of HiRDB Dataextractor is able to perform data linkage only between HiRDB databases. It cannot perform data linkage with the following databases:

ORACLE

XDM/RD

Sequential data sets

Additionally, the English version of HiRDB Dataextractor Version 8 is supported only in the Windows version of HiRDB. Therefore, although this manual includes explanations of the UNIX version of HiRDB Dataextractor, no English version is supported in UNIX.

Intended readers

This manual is intended for system administrators and system designers who use HiRDB Dataextractor to link data. The manual assumes that the reader has a basic understanding of the following:

Operating system under which HiRDB Dataextractor is running

HiRDB

XDM E2 (only if you will link data with XDM)

XDM/XT (only if you will link data with a database on a mainframe using XDM/XT)

Organization of the manual

This manual is organized as follows:

1. Overview of HiRDB Dataextractor

Chapter 1 describes the features and functions of HiRDB Dataextractor.

2. HiRDB Dataextractor Environment Setup

Chapter 2 describes the software configuration of HiRDB Dataextractor and its environment setup procedure.

3. Extracting and Importing Data and Creating Files

Chapter 3 explains the procedures for extracting and importing data and for creating files.

4. Extracting Data from HiRDB and Importing It into HiRDB

Chapter 4 explains the procedures for extracting data from a HiRDB database and importing it into a HiRDB table or specifying information for file creation.

5. Extracting Data from ORACLE and Importing It into HiRDB

Chapter 5 explains the procedures for extracting data from an ORACLE database and importing it into a HiRDB table or specifying information for file creation.

6. Operation

Chapter 6 explains the procedures for starting and terminating HiRDB Dataextractor.

7. Error Handling Procedures

Chapter 7 explains the error handling procedures.

8. Messages

Chapter 8 explains the messages that are issued by HiRDB Dataextractor.

A. Memory and File Requirements

Appendix A explains the memory and file size requirements for HiRDB Dataextractor.

B. Functional Differences with Windows

Appendix B explains the functional differences when the Windows operating system is used.

C. Functional Differences with Solaris

Appendix C explains the functional differences when the Solaris operating system is used.

D. Functional Differences with Linux

Appendix D explains the functional differences when the Linux operating system is used.

E. Functional Differences with AIX

Appendix E explains the functional differences when the AIX operating system is used.

Related publications

This manual is part of a related set of manuals. The manuals in the set are listed below (with the manual numbers).

HiRDB (for Windows)

For Windows Systems HiRDB Version 8 Description (3020-6-351(E))

For Windows Systems HiRDB Version 8 Installation and Design Guide (3020-6-352(E))

For Windows Systems HiRDB Version 8 System Definition (3020-6-353(E))

For Windows Systems HiRDB Version 8 System Operation Guide (3020-6-354(E))

For Windows Systems HiRDB Version 8 Command Reference (3020-6-355(E))

HiRDB (for UNIX)

For UNIX Systems HiRDB Version 8 Description (3000-6-351(E))

For UNIX Systems HiRDB Version 8 Installation and Design Guide (3000-6-352(E))

For UNIX Systems HiRDB Version 8 System Definition (3000-6-353(E))

For UNIX Systems HiRDB Version 8 System Operation Guide (3000-6-354(E))

For UNIX Systems HiRDB Version 8 Command Reference (3000-6-355(E))

HiRDB Staticizer Option Version 7 Description and User's Guide (3000-6-282(E))

For UNIX Systems HiRDB Version 8 Disaster Recovery System Configuration and Operation Guide (3000-6-364)*

HiRDB (for both Windows and UNIX)

HiRDB Version 8 UAP Development Guide (3020-6-356(E))

HiRDB Version 8 SQL Reference (3020-6-357(E))

HiRDB Version 8 Messages (3020-6-358(E))

HiRDB Datareplicator Version 8 Description, User's Guide and Operator's Guide (3020-6-360(E))

HiRDB Dataextractor Version 8 Description, User's Guide and Operator's Guide (3020-6-362(E))

* This manual has been published in Japanese only; it is not available in English.

You must use the UNIX or the Windows manuals, as appropriate to the platform you are using.

Organization of HiRDB manuals

The HiRDB manuals are organized as shown below. For the most efficient use of these manuals, it is suggested that they be read in the order they are shown, going from left to right.

Conventions: Abbreviations

This manual uses the following abbreviations for product names:

Name of product or other entity
Representation

HiRDB/Single Server Version 8
HiRDB/Single Server
HiRDB or HiRDB Server

HiRDB/Single Server Version 8 (64)

HiRDB/Parallel Server Version 8
HiRDB/Parallel Server

HiRDB/Parallel Server Version 8 (64)

HiRDB/Developer's Kit Version 8
HiRDB/Developer's Kit
HiRDB Client

HiRDB/Developer's Kit Version 8 (64)

HiRDB/Run Time Version 8
HiRDB/Run Time

HiRDB/Run Time Version 8 (64)

HiRDB Datareplicator Version 8
HiRDB Datareplicator

HiRDB Datareplicator Version 8 (64)

HiRDB Dataextractor Version 8
HiRDB Dataextractor

HiRDB Dataextractor Version 8 (64)

XDM/RD E2
XDM/RD
XDM/RD

AIX 5L
AIX

HP-UX 11i V2 (PA-RISC)
HP-UX

HP-UX 11i V2 (IPF)
HP-UX or HP-UX (IPF)

Red Hat Linux
Linux

Red Hat Enterprise Linux

Red Hat Enterprise Linux AS 3 (IPF)
Linux (IPF)
Linux

Red Hat Enterprise Linux AS 4 (IPF)

Red Hat Enterprise Linux AS 3 (AMD64 & Intel EM64T)
Linux (EM64T)

Red Hat Enterprise Linux AS 4 (AMD64 & Intel EM64T)

Red Hat Enterprise Linux ES 3 (AMD64 & Intel EM64T)

Red Hat Enterprise Linux ES 4 (AMD64 & Intel EM64T)

Microsoft(R) Windows(R) 2000 Professional Operating System
Windows 2000

Microsoft(R) Windows(R) 2000 Server Operating System

Microsoft(R) Windows(R) 2000 Advanced Server Operating System

Microsoft(R) Windows(R) 2000 Datacenter Server Operating System

Microsoft(R) Windows(R) XP Professional Operating System
Windows XP Professional
Windows XP

Microsoft(R) Windows(R) XP Professional x64 Edition
Windows XP x64 Edition

Microsoft(R) Windows ServerTM 2003, Standard Edition
Windows Server 2003

Microsoft(R) Windows ServerTM 2003, Enterprise Edition

Microsoft(R) Windows ServerTM 2003, Standard x64 Edition
Windows Server 2003 x64 Editions
Windows Server 2003

Microsoft(R) Windows ServerTM 2003, Enterprise x64 Edition

64 bit Version Microsoft(R) Windows ServerTM 2003, Enterprise Edition (IPF)
Windows Server 2003 (IPF)

Microsoft(R) Windows ServerTM 2003 R2, Standard Edition
Windows Server 2003 R2

Microsoft(R) Windows ServerTM 2003 R2, Enterprise Edition

Microsoft(R) Windows ServerTM 2003 R2, Standard x64 Edition
Windows Server 2003 R2 or Windows Server 2003 R2 x64 Editions

Microsoft(R) Windows ServerTM 2003 R2, Enterprise x64 Edition

Windows 2000, Windows XP, and Windows Server 2003 may be referred to collectively as Windows. In explanations about HiRDB clients, such references may include Windows Me. Note, however, that any of the above operating systems may be referred to explicitly if required for reasons of clarity.

The xtrepO command is referred to as the xtrep command, unless noted otherwise.

The following ORACLE attributes are represented as BLOB, unless noted otherwise: LONG, LONG RAW, BLOB, CLOB, NCLOB, and BFILE.

Conventions: Diagrams

This manual uses the following conventions in diagrams:

Conventions: Fonts and symbols

Font and symbol conventions are classified as:

General font conventions

Conventions in syntax explanations

These conventions are described below.

General font conventions

The following table lists the general font conventions:

Font
Convention

Bold
Bold type indicates text on a window, other than the window title. Such text includes menus, menu options, buttons, radio box options, or explanatory labels. For example, bold is used in sentences such as the following:

From the File menu, choose Open.

Click the Cancel button.

In the Enter name entry box, type your name.

Italics
Italics are used to indicate a placeholder for some actual text provided by the user or system. Italics are also used for emphasis. For example:

Write the command as follows:
copy source-file target-file

Do not delete the configuration file.

Code font
A code font indicates text that the user enters without change, or text (such as messages) output by the system. For example:

At the prompt, enter dir.

Use the send command to send mail.

The following message is displayed:
The password is incorrect.

Examples of coding and messages appear as follows (although there may be some exceptions, such as when coding is included in a diagram):

MakeDatabase
...
StoreDatabase temp DB32

In examples of coding, an ellipsis (...) indicates that one or more lines of coding are not shown for purposes of brevity.

Conventions in syntax explanations

Syntax definitions appear as follows:

StoreDatabase [temp|perm] (database-name ...)

The following table lists the conventions used in syntax explanations:

Example font or symbol | Convention
StoreDatabase | Code-font characters must be entered exactly as shown.
database-name | This font style marks a placeholder that indicates where appropriate characters are to be entered in an actual command.
SD | Bold code-font characters indicate the abbreviation for a command.
perm | Underlined characters indicate the default value.
[ ] | Square brackets enclose an item or set of items whose specification is optional.
{ } | One of the items enclosed in brackets must be specified.
| | Only one of the options separated by a vertical bar can be specified at the same time.
... | An ellipsis (...) indicates that the item or items enclosed in ( ) or [ ] immediately preceding the ellipsis may be specified as many times as necessary.
() | Parentheses indicate the range of items to which the vertical bar (|) or ellipsis (...) is applicable.
~ | The user-specified value preceding the swung dash must be specified in accordance with the attributes following the swung dash.
< > | Angle brackets enclose the syntax element notation for a user-specified value.
<< >> | Double angle brackets enclose the default value assumed by the system when the specification is omitted.
(( )) | Double parentheses enclose the permitted range of values that can be specified.

Syntax element notations

Syntax element notations explain the types of user-specified values.

Syntax element notation | Explanation
alphabetic | Alphabetic characters (A-Z, a-z) and _ (underscore)
alphabetic symbol | Alphabetic characters (A-Z, a-z), #, @, \
alphanumeric | Alphabetic characters and numeric characters (0-9)
alphanumeric symbol | Alphabetic symbols and numeric characters (0-9)
unsigned integer | Numeric characters (0-9)
hexadecimal | Numeric characters (0-9)and A-F (or a-f)
identifier | Alphanumeric character (A-Z, a-z) string beginning with an alphabetic character
symbolic name | Alphanumeric symbol string beginning with an alphabetic symbol
character string | String consisting of any characters
pathname | String consisting of one or more symbolic names, forward slashes (/), periods (.), or backslashes (\)
filename | Character string consisting of alphabetic characters (A-Z, a-z), numeric characters (0-9), a period (.), underscore (_), and the at mark (@) (maximum 30 characters)

Note

Use single-byte characters only. Alphabetic characters are case-sensitive (i.e., lowercase alphabetic characters are distinguished from uppercase alphabetic characters). Path names are also dependent on the operating system being used.

Notations used in calculation formulas

The following notations are used in formulas:

Notation
Explanation

The resulting value is to be rounded up.

Example

The result of 34 3 is 12.

The resulting value is to be rounded off.

Example

The result of 34 3 is 11.

(nnnn)₁₆
Indicates a hexadecimal number.

Example

(12AB)₁₆ indicates the hexadecimal value 12AB.

Conventions: KB, MB, GB, and TB

This manual uses the following conventions:

1 KB (kilobyte) is 1,024 bytes.

1 MB (megabyte) is 1,024² bytes.

1 GB (gigabyte) is 1,024³ bytes.

1 TB (terabyte) is 1,024⁴ bytes.

Conventions: Version numbers

The version numbers of Hitachi program products are usually written as two sets of two digits each, separated by a hyphen. For example:

Version 1.00 (or 1.0) is written as 01-00.

Version 2.05 is written as 02-05.

Version 2.50 (or 2.5) is written as 02-50.

Version 12.25 is written as 12-25.

The version number might be shown on the spine of a manual as Ver. 2.00, but the same version number would be written in the program as 02-00.

Log representations

In the Windows version of HiRDB:

The application log that is displayed by Windows Event Viewer is referred to as the event log. The following procedure is used to view the event log.

To view the event log:

1. Choose Start, Programs, Administrative Tools (Common), and then Event Viewer.

2. Choose Log, and then Application.

3. The application log is displayed. Messages with HiRDBSingleServer or HiRDBParallelServer displayed in the Source column were issued by HiRDB.

If you specified a setup identifier when you installed HiRDB, the specified setup identifier follows HiRDBSingleServer or HiRDBParallelServer.

In the UNIX version of HiRDB:

The OS log is referred to generically as syslogfile. syslogfile is the log output destination specified in /etc/syslog.conf. Typically, the following files are specified as syslogfile.

OS | File
HP-UX | /var/adm/syslog/syslog.log
Solaris | /var/adm/messages or /var/log/syslog
AIX 5L | /var/adm/ras/syslog
Linux | /var/log/messages

Notations used in explanations of Windows operations

In this manual, the term directory includes both of the Windows terms directory and folder, and path names are delimited by forward slashes (/). If you are using the Windows version of Datareplicator, you must replace instances of the forward slash with the back slash (\).

Sources of HiRDB relational database language

The HiRDB relational database language described in this manual was developed by adding Hitachi's unique interpretations and specifications to the following standards. Hitachi expresses its appreciation to the developers and acknowledges the sources of these specifications.

HiRDB relational database

JIS | X3005-1997 | Database Language SQL
IS | ISO9075-1992 | Information processing systems - Database Language SQL
ANS | X3.135-1986 | Information system - Database Language SQL

1. Overview of HiRDB Dataextractor

This chapter describes the features and functions of HiRDB Dataextractor.

Organization of this chapter

1.1 Features

1.2 Functions

1.1 Features

This section describes the purpose and features of HiRDB Dataextractor.

There has been a strong demand in recent times for an effective method of integrating and utilizing core data created by corporate activities. The demand is to fully utilize this data in information-based, application-specific work areas, such as for decision making and for providing strategic services. A core database, however, must always provide high performance and storage efficiency. Using such a core database might result in decreased performance or storage efficiency, and the core database might not be optimized for the desired purpose.

HiRDB Dataextractor is a program designed to solve such problems. You can use HiRDB Dataextractor to extract any data from core databases and create databases for particular purposes. You can also move from a single company-wide database to departmental databases as your client/server system expands, or you can back up databases from one server to another. Combined with XDM/XT, HiRDB Dataextractor can be used with databases on a mainframe to extract and import data.

HiRDB Dataextractor enables you to construct a database system that efficiently utilizes required information at any location. HiRDB Dataextractor can extract specified data from a database and create a new database consisting of the extracted data. It can also use extracted data to create an input file to another database.

HiRDB Dataextractor can extract data, import data, and create files between various database systems. For example, HiRDB Dataextractor can:

Extract and import data between HiRDBs on workstations or personal computers.

Extract and import data between a mainframe and a HiRDB or ORACLE database on a workstation or personal computer.

Create files at a workstation or personal computer using data extracted from a mainframe database or a HiRDB or ORACLE database.

Figure 1-1 provides an overview of HiRDB Dataextractor. Table 1-1 lists the systems that support use of HiRDB Dataextractor for data linkage.

Figure 1-1 Overview of HiRDB Dataextractor

Table 1-1 Systems supporting use of HiRDB Dataextractor for data linkage

Extracted system (applicable OS)
Target/file creation system (applicable OS)

HiRDB
(HP-UX, Windows, Solaris, Linux, AIX)
HiRDB (HP-UX, Windows, Solaris, Linux, AIX)

Input file to database
(HP-UX, Windows, Solaris, Linux, AIX)¹

XDM/RD (VOS3)

Sequential dataset (VOS3)²

ORACLE (HP-UX, Windows, Solaris, Linux, AIX)
HiRDB (HP-UX, Windows, Solaris, Linux, AIX)

Input file to database
(HP-UX, Windows, Solaris, Linux, AIX)¹

XDM/RD (VOS3)

Sequential dataset (VOS3)²

XDM/RD (VOS3)
HiRDB (HP-UX, Windows, Solaris, Linux, AIX)

Input file to database
(HP-UX, Windows, Solaris, Linux, AIX)¹

Sequential dataset (VOS3)³
HiRDB (HP-UX, Windows, Solaris, Linux, AIX)

Input file to database
(HP-UX, Windows, Solaris, Linux, AIX)¹

Extracted system: System from which data is extracted.

Target/file creation system: System to which extracted data is imported or where a file is created using extracted data.

Note

If both the extracted system and the target/file creation system use the same model of HiRDB Dataextractor, their versions must be the same.

¹ A file created by HiRDB Dataextractor can be used to import data into any database system.

² XDM/XT can use a sequential dataset to receive extracted data. The created dataset is in the format of a VOS3-supported sequential dataset, so it can be used in database systems that do not support XDM/XT.

³ An extracted dataset created by XDM/XT is supported. This makes it possible to import data from an XDM/SD E2 or ADM database into a HiRDB database or any other database system. Any VOS3-supported sequential dataset format is supported, thereby providing support for database systems that do not support XDM/XT.

Organization of this section

(1) Extracting and importing data between HiRDBs on workstations or personal computers

(2) Extracting ORACLE data from a workstation or personal computer

(3) Extracting and importing data between a mainframe and a HiRDB on a workstation or personal computer

(4) Importing ORACLE data from a workstation or personal computer into a mainframe database

(5) Creating a file using data extracted from a mainframe database or a HiRDB or ORACLE database at a workstation or personal computer

(1) Extracting and importing data between HiRDBs on workstations or personal computers

You can extract and import data between HiRDBs on workstations or personal computers.

You can extract data from a HiRDB database and import it into another HiRDB database. This makes it possible to construct a database for a departmental server from a database at the key server for HiRDB or to back up a database from one HiRDB database into another HiRDB database.

It is also possible to output data extracted from a HiRDB database to a file and to use this file to import the data into another HiRDB database. Such a file can be used as the extracted HiRDB database's backup file and can be imported into the target HiRDB database by the user at any time.

You use the following protocol to extract and import data between HiRDBs on workstations or personal computers:

TCP/IP protocol

(2) Extracting ORACLE data from a workstation or personal computer

You can extract ORACLE data from a workstation or personal computer.

You can extract data from an ORACLE database and import it into a HiRDB database at another workstation or personal computer. This makes it possible to construct a database for a departmental server from a database at the key server for ORACLE or to back up an ORACLE database into a HiRDB database. It is also possible to output data extracted from an ORACLE database to a file and to use this file to import the data into a HiRDB database. You can use the following protocol to extract ORACLE data from a workstation or personal computer and import it into a HiRDB database at another workstation or personal computer:

TCP/IP protocol

(3) Extracting and importing data between a mainframe and a HiRDB on a workstation or personal computer

You can extract and import data between a mainframe database and a HiRDB database at a workstation or personal computer.

When used in conjunction with XDM/XT, which is a mainframe database extraction program, HiRDB Dataextractor can create a HiRDB database from a mainframe database, and vice versa. It can also create a VOS3-supported sequential dataset from a HiRDB database.

These capabilities enable end users to make use of the most recently available data in the mainframe computer. In addition, information in departmental servers that is updated from workstations or personal computers can be imported into the mainframe database.

You use either of the following protocols to extract and import data between a mainframe and a HiRDB on a workstation or personal computer:

TCP/IP protocol

OSI protocol

To extract data, import data, or create a sequential dataset between mainframe and HiRDB databases, you must specify the method of data extraction, import, or file creation during execution of XDM/XT.

(4) Importing ORACLE data from a workstation or personal computer into a mainframe database

You can import ORACLE data from a workstation or personal computer into a mainframe database.

When used in conjunction with XDM/XT, which is a mainframe database extraction program, HiRDB Dataextractor can create a mainframe database from an ORACLE database or create a VOS3-supported sequential dataset from an ORACLE database. This makes it possible to import information updated in departmental servers from workstations or personal computers into the mainframe database. You can use either of the following protocols to import ORACLE data from a workstation or personal computer into a mainframe database:

TCP/IP protocol

OSI protocol

To extract data, import data, or create a sequential dataset between mainframe and HiRDB databases, you must specify the method of data extraction, import, or file creation during execution of XDM/XT.

(5) Creating a file using data extracted from a mainframe database or a HiRDB or ORACLE database at a workstation or personal computer

You can create an input file to a database system by extracting data from a HiRDB or ORACLE database.

When used in conjunction with XDM/XT, HiRDB Dataextractor enables you to create an input file to a database system using data from a mainframe database. You can use such a created file as the extracted HiRDB database's backup file or to import the data into a target HiRDB database at any time.

By using a file, you are able to import extracted data into a database at any database system other than HiRDB.

You use either of the following protocols to create a file from extracted data:

TCP/IP protocol

OSI protocol

To create a file from data extracted from a mainframe database, you must specify the data extraction and file creation methods during execution of XDM/XT.

1.2 Functions

This section describes the functions of HiRDB Dataextractor.

HiRDB Dataextractor provides three facilities:

Data extraction facility
The data extraction facility extracts data from a specified database and sends the extracted data to a target system. The user selects the data to be extracted. It is also possible to add columns to the extracted data.
The system used to execute the data extraction facility is referred to as the source system.

Data import facility
The data import facility receives data from a source system and imports it into a target table. This facility uses HiRDB's database load utility (pdload) to import data into a HiRDB table.
The system used to execute the data import facility is referred to as the target system. For details about the HiRDB database load utility (pdload), see the HiRDB Command Reference manual.
The data import facility cannot be used to import data into an ORACLE table.

File creation facility
The file creation facility receives data from a source system and saves it as a file. This facility enables data linkage with non-HiRDB database systems.
The system used to execute the file creation facility is referred to as the file creation system.

Figure 1-2 provides an overview of data extraction and import between a mainframe database (XDM/RD) and a HiRDB or ORACLE database (TCP/IP connection).

Figure 1-3 provides an overview of data extraction and import between a mainframe database (XDM/RD) and a HiRDB or ORACLE database (OSI connection).

Figure 1-4 provides an overview of data extraction from a HiRDB or ORACLE database and its import into a HiRDB database.

Figure 1-5 provides an overview of data extraction from a HiRDB or ORACLE database and creation of a file.

Figure 1-2 Overview of data extraction and import between a mainframe database (XDM/RD) and a HiRDB or ORACLE database (TCP/IP connection)

Figure 1-3 Overview of data extraction and import between a mainframe database (XDM/RD) and a HiRDB or ORACLE database (OSI connection)

Figure 1-4 Overview of data extraction from a HiRDB or ORACLE database and its import into a HiRDB database

Figure 1-5 Overview of data extraction from a HiRDB or ORACLE database and creation of a file

2. HiRDB Dataextractor Environment Setup

This chapter describes the software configuration of HiRDB Dataextractor, its environment setup procedure, and preparations before execution.

Organization of this chapter

2.1 Software configuration

2.2 Environment setup procedure

2.3 Preparations before execution

2.1 Software configuration

This section describes the software configuration required in order to use HiRDB Dataextractor. Table 2-1 lists the program products related to execution of HiRDB Dataextractor.

Table 2-1 Related program products

Program product
Required
Remarks

HP-UX
Windows
Solaris
Linux
AIX
Y
N/A

HiRDB
C
One of the HiRDB systems is required in order to extract data from HiRDB or to import data into HiRDB.

HiRDB Text Search Plug-in
C
Required in order to use columns of the HiRDB abstract data type (SGMLTEXT type).

XNF/H/BASE
C
Required when the operating system being used is HP-UX and the OSI protocol is used.

XNF/H/ACONARC
C

XDM/RD
C
One of the XDM/RD systems is required in the following cases:

To extract data from XDM/RD or to import data into XDM/RD

To create a file from XDM/RD

XDM/XT
C
Required in the following cases:

To extract data from XDM/RD and then either import it into HiRDB or create a file

To extract data from a sequential dataset and then either import it into HiRDB or create a file

To extract data from HiRDB and then either import it into XDM/RD or create a sequential dataset

ORACLE
C
Required in order to extract data from ORACLE.

Y: One of the program products listed below is required.

C: Program product is required depending on the conditions.

The software configuration of HiRDB Dataextractor depends on the protocol that is used. Figures 2-1 and 2-2 show the software configurations of HiRDB Dataextractor.

Figure 2-1 Software configuration (TCP/IP connection)

Figure 2-2 Software configuration (OSI connection)

2.2 Environment setup procedure

This section explains the environment setup procedure for using HiRDB Dataextractor.

Organization of this section

2.2.1 Environment setup procedure

2.2.2 Installing HiRDB Dataextractor

2.2.3 Specifying environment variables

2.2.4 Files required in order to use HiRDB Dataextractor

2.2.1 Environment setup procedure

Figure 2-3 shows the environment setup procedure for using HiRDB Dataextractor.

Figure 2-3 Environment setup procedure

2.2.2 Installing HiRDB Dataextractor

Organization of this subsection

(1) Host used to install HiRDB Dataextractor

(2) Directories and files created by HiRDB Dataextractor

(3) File naming conventions

(1) Host used to install HiRDB Dataextractor

Table 2-2 shows the host at which HiRDB Dataextractor is to be installed.

Table 2-2 Host used to install HiRDB Dataextractor

Type
Source system
Target system
File creation system

Host used to install HiRDB Dataextractor¹
For a HiRDB/Single Server:

Host at which the single server is located

For a HiRDB/Single Server:

Host at which the single server is located

Host used to create the file

For a HiRDB/Parallel Server, host at which one of the following is located:

System manager

Front-end server

Back-end server

Dictionary server

For a HiRDB/Parallel Server, host at which one of the following is located:²

System manager

Server at the data transmission destination³

For ORACLE:

Host at which ORACLE is located

¹ If you are using the OSI protocol, connection between XDM/XT and the host used to install HiRDB Dataextractor must be established with the OSI protocol.

² Connection between XDM/XT and the server at the data transmission destination must be established with the OSI protocol. Use of the OSI protocol is optional for the connection between the host containing the system manager and XDM/XT.

³ If you are transmitting data to the front-end server, the target system is the host located at the front-end server (to which data is to be transmitted). If you are transmitting data stored by RDAREA directly to a back-end server, the target system is the host at which the back-end server is located.

(2) Directories and files created by HiRDB Dataextractor

Table 2-3 lists the directories and files that are created by HiRDB Dataextractor. HiRDB Dataextractor creates directories and files at the host where it is installed. If this host already contains a directory or file with one of these names, you must save the directory or file under a different name.

Table 2-3 Directories and files created by HiRDB Dataextractor

Name of directory or file
Creation time
Description
Type

Source
Target
Creation

/opt/HIRDBXT/
Installation
Directory used to store HiRDB Dataextractor's various directories and files
C
C
C

/opt/HIRDBXT/bin
Directory used to store HiRDB Dataextractor's executable files (HiRDB Dataextractor's load modules and commands are stored in this directory)
C
C
C

/opt/HIRDBXT/bin/xtrep
Files for HiRDB Dataextractor's xtrep command
C
C
C

/opt/HIRDBXT/bin/xtstart
Files for HiRDB Dataextractor's xtstart command
C
C
C

/opt/HIRDBXT/bin/xtmsgtext
Text files used to output HiRDB Dataextractor messages
C
C
C

/opt/HIRDBXT/obj
Object storage directory
C
C
C

/opt/HIRDBXT/obj/pxto8160.o
Object for ORACLE extraction
C
C
C

/opt/HIRDBXT/lib
Libraries storage directory
C
C
C

/opt/HIRDBXT/lib/maptable/euc2jis.map
Mapping table for converting character codes (from EUC to SJIS)
C
C
C

/opt/HIRDBXT/lib/maptable/eucg2jis.map
Mapping table for converting character codes (from EUC to SJIS)
C
C
C

/opt/HIRDBXT/lib/maptable/euc2ucs2.map
Mapping table for converting character codes (from EUC to UCS2)
C
C
C

/opt/HIRDBXT/lib/maptable/eucg2u.map
Mapping table for converting character codes (from EUC to UCS2)
C
C
C

/opt/HIRDBXT/lib/maptable/jis2euc.map
Mapping table for converting character codes (from SJIS to EUC)
C
C
C

/opt/HIRDBXT/lib/maptable/jis2ucs2.map
Mapping table for converting character codes (from SJIS to UCS2)
C
C
C

/opt/HIRDBXT/lib/maptable/ucs22euc.map
Mapping table for converting character codes (from UCS2 to EUC)
C
C
C

/opt/HIRDBXT/lib/maptable/ucs22jis.map
Mapping table for converting character codes (from UCS2 to SJIS)
C
C
C

/opt/HIRDBXT/lib/usermap
When a mapping table is updated by the xtccnvedt command
Directory for mapping tables for converting user's character codes
--
C
C

/opt/HIRDBXT/lib/pxtora01.sl
At make in user environment
Library for ORACLE extraction
C
--
C

/opt/HIRDBXT/spool/¹
Installation
Directory used to store files output during HiRDB Dataextractor operation
C
C
C

/opt/HIRDBXT/spool/xter
HiRDB Dataextractor operation
HiRDB Dataextractor's error log file for TCP/IP
TCP²
TCP³
TCP³

/opt/HIRDBXT/spool/xtlog...
HiRDB Dataextractor's error log file for OSI
OSI³
OSI³
OSI³

/opt/HIRDBXT/spool/pder...
HiRDB database load utility's error files
--
C³
--

/opt/HIRDBXT/spool/.xtpc...
HiRDB database load utility's temporary error files
--
T³
--

/opt/HIRDBXT/spool/pdin... or /opt/HIRDBXT/spool/.pdin...
HiRDB database load utility's input data files
--
T³
--

/opt/HIRDBXT/spool/pdcf...
HiRDB Dataextractor operation
HiRDB database load utility's control information files
--
R³
--

/opt/HIRDBXT/spool/pdnf...
HiRDB database load utility's null value information files
--
R³
--

$XTTMPDIR/...
Output files
For details about the filenames, see (3)(a) in 2.2.2 Installing HiRDB Dataextractor.
--
R⁴
C

/opt/HIRDBXT/spool/...

/opt/HIRDBXT/spool/.pden...
EOF notification file for the HiRDB database load utility
--
T³
--

$XTTMPDIR/...
LOB input file storage directory
For details about the filenames, see (3)(b) in 2.2.2 Installing HiRDB Dataextractor.
--
C⁵
C⁵

/opt/HIRDBXT/spool/...

$XTTMPDIR/.../xtlbf...
LOB input files
For details about the filenames, see (3)(c) in 2.2.2 Installing HiRDB Dataextractor.
--
C⁵
C⁵

/opt/HIRDBXT/spool/.../xtlbf...

/opt/HIRDBXT/dump⁶
Directory for storing the module trace files used by HiRDB Dataextractor
C
C
C

/opt/HIRDBXT/dump/xtmt...
Module trace files that are output in the event of an error
C
C
C

/opt/HIRDBXT/dump/process-ID
Directory for storing core files for each load operation
C
C
C

/opt/HIRDBXT/dump/process-ID/core
Core files that are output in the event of an error
C
C
C

C: Created.

--: Not created.

T: File that is created temporarily when data is imported without creating an output file. Such a file is deleted when the processing is completed.

R: File that is retained even after the processing is completed because the -o option is specified in the xtrep command. If the -o option is omitted, such a file is deleted after processing is completed. However, if an error occurs during importing, the file is not deleted.

TCP: Created when the TCP/IP protocol is used.

OSI: Created when the OSI protocol is used.

Source: Source system

Target: Target system

Creation: File creation system

¹ Because /opt/HIRDBXT/spool contains files that are created dynamically by HiRDB Dataextractor, you must not delete /opt/HIRDBXT/spool. Also, you must not reference or delete any file under /opt/HIRDBXT/spool while HiRDB Dataextractor is active. You should delete these files periodically while HiRDB Dataextractor is stopped.

² This file is not created if an error occurs during parameter analysis. In such a case, error messages are output only to the standard output. You can output error messages to any file by specifying its filename in the -e option of the xtrep command. If the -e option is omitted, HiRDB Dataextractor assigns a unique filename. If you specify the XTTEMPNAM environment variable, you can use the date/time or the tempnam function to specify a name.

³ HiRDB Dataextractor assigns a unique filename. If you specify the XTTEMPNAM environment variable, you can use the date/time or the tempnam function to specify a name.

⁴ Such a file is created when the -o or -O option is specified in the xtrep command.

⁵ Such a file is created when the extracted data contains LOB data. If the -o option is specified in the xtrep command, this file is retained even after processing is completed; if the -o option is omitted, this file is deleted after processing is completed.

⁶ You should delete the files under /usr/HIRDBXT/dump periodically while HiRDB Dataextractor is stopped; use the XTTRCDIR environment variable to specify the desired directory name.

(3) File naming conventions

This section explains the conventions used by HiRDB Dataextractor to determine names for the following files, which are created by HiRDB Dataextractor:

Output files

LOB input file storage directory

LOB input files

(a) Output files

HiRDB Dataextractor determines names for output files on the basis of the following specifications:

-o or -O option in the xtrep command

XTTMPDIR environment variable

XTTEMPNAM environment variable

You can use the -o or -O option in the xtrep command or the XTFILESIZE environment variable to divide data and output it to multiple files. Table 2-4 lists the names of the output files. To specify the file mode for output files, use the XTFPERMIT environment variable.

Table 2-4 Names of output files

Specification | Name of output file
-o or -O option specified | Value of -o or -O option | XTFILESIZE environment variable specified | XTTMPDIR environment variable specified
Y | One file | Y | Y | $XTTMPDIR/specified-value-sequence-number
N | .../spool/specified-value-sequence-number
N | Y | $XTTMPDIR/specified-value
N | .../spool/specified-value
Multiple files | N/A | Y | $XTTMPDIR/specified-value-x-files-count
N | .../spool/specified-value-x-files-count
Y | One directory | Y | Y | $XTTMPDIR/specified-value/file-prefix¹-year.month.date-hour.minute.second-sequence-number
N | .../spool/specified-value/file-prefix¹-year.month.date-hour.minute.second-sequence-number
N | Y | $XTTMPDIR/specified-value/file-prefix¹-year.month.date-hour.minute.second
N | .../spool/specified-value/file-prefix¹-year.month.date-hour.minute.second
Multiple directories | N/A | Y | $XTTMPDIR/specified-value/file-prefix¹-year.month.date-hour.minute.second-sequence-number-x-directories-count
N | .../spool/specified-value/file-prefix¹-year.month.date-hour.minute.second-sequence-number-x-directories-count
Not specified | Y | Y | $XTTMPDIR/file-prefix¹-year.month.date-hour.minute.second-sequence-number
N | .../spool/file-prefix¹-year.month.date-hour.minute.second-sequence-number
N | Y | $XTTMPDIR/file-prefix¹-year.month.date-hour.minute.second
N | .../spool/file-prefix¹-year.month.date-hour.minute.second
N | Not specified | N/A | N/A | .../spool/.pdin-year.month.date-hour.minute.second ²

...: Depends on the operating system being used:

HP-UX, Solaris, Linux, or AIX: /opt/HIRDBXT

Windows: installation-directory-name

Y: Specified.

N: Not specified.

N/A: Not applicable.

specified-value: Name specified in the -o or -O option.

$XTTMPDIR: Value specified in the XTTMPDIR environment variable.

¹ When the XTSQL environment variable is set to 0 or omitted: extracted-table-name

When the XTSQL environment variable is set to 1: xtof-process-ID

² If the value 0 is specified in the XTTEMPNAM environment variable, HiRDB Dataextractor uses the value created by the tempnam function for -year.month.date-hour.minute.second.

Output file creation example 1

To only create a file, assigning a unique name to the output file:

When you specify the -o option but do not specify a value, HiRDB Dataextractor assigns a unique filename. The file is created under the directory specified in the XTTMPDIR environment variable.

Environment variables

XTFILESIZE: None
XTTMPDIR: /tmp

xtrep command

xtrep -R -o TBL_NAME

Filename

/tmp/TBL_NAME-99.06.11-10.00.00

Output file creation example 2

To import data into a HiRDB table, dividing the data and creating multiple files in the same partition:

Specify the XTFILESIZE environment variable in order to divide the file. Because the XTTMPDIR environment variable is not specified in this example, the file is created under .../spool.

Environment variables

XTFILESIZE: 100000
XTTMPDIR: None

xtrep command

xtrep -o TBL_NAME

Filenames

.../spool/TBL_NAME-99.06.11-10.00.00-1
.../spool/TBL_NAME-99.06.11-10.00.00-2
                 :
                 :
.../spool/TBL_NAME-99.06.11-10.00.00-n

A file is divided in units of 100,000 bytes, and the maximum file size is as follows because no record spans files:

100K/L x L

L: Record length

Output file creation example 3

To only create files, dividing the data and creating multiple DAT-format files in separate partitions:

If you specify multiple partitions with the -o option, HiRDB Dataextractor creates files in separate partitions. Because the XTFILESIZE environment variable is not specified in this example, HiRDB Dataextractor fills one partition, and then creates a file in another partition.

HP-UX

Environment variables

XTFILESIZE: None
XTTMPDIR: /

xtrep command

xtrep -R dat -o HD000/, HD001/ TBL_NAME

Filenames

/HD000/TBL_NAME-99.06.11-10.00.00
/HD001/TBL_NAME-99.06.11-10.00.00

When /HD000 becomes full, HiRDB Dataextractor creates a file in /HD001.

Windows

Environment variables

XTFILESIZE: None
XTTMPDIR: \

xtrep command

xtrep -R dat -o C:\DATA\,D:\DATA\ TBL_NAME

Filenames

C:\DATA\TBL_NAME-99.06.11-10.00.00
D:\DATA\TBL_NAME-99.06.11-10.00.00

When C:\DATA becomes full, HiRDB Dataextractor creates a file in D:\DATA.

(b) LOB input file storage directory

If extracted data contains BLOB columns, HiRDB Dataextractor creates a LOB input file for each LOB data item. The directory used to store these LOB input files is the LOB input file storage directory.

HiRDB Dataextractor determines the name of the LOB input file storage directory on the basis of the following specifications:

-b option in the xtrep command

XTTMPDIR environment variable

XTTEMPNAM environment variable

Table 2-5 shows the name of the LOB input file storage directory.

Instead of creating LOB input files, you can store data for BLOB columns in the same output file for non-BLOB data by specifying the XTLOBKIND environment variable. Additionally, you can use the XTDPERMIT environment variable to specify a file mode for the LOB input file storage directory.

Table 2-5 Name of the LOB input file storage directory

Specification | Name of LOB input file storage directory
-b option | XTTMPDIR environment variable
Y | Y | $XTTMPDIR/-b-option-value
N | .../spool/-b-option-value
N | Y | $XTTMPDIR/xtlb-year.month.date-hour.minute.second-process-ID*
N | .../spool/xtlb-year.month.date-hour.minute.second-process-ID*

...: Depends on the operating system being used:

HP-UX, Solaris, or Linux, AIX: /opt/HIRDBXT

Windows: installation-directory-name

Y: Specified.

N: Not specified.

$XTTMPDIR: Value specified in the XTTMPDIR environment variable.

* If the value 0 is specified in the XTTEMPNAM environment variable, HiRDB Dataextractor uses the value created by the tempnam function for -year.month.date-hour.minute.second-process-ID.

(c) LOB input files

HiRDB Dataextractor creates LOB input files with a unique filename for each LOB data item in the LOB input file storage directory.

The following shows the convention for naming LOB input files:

xtlbf-data-item-number-BLOB-column-number

data-item-number: Sequence number beginning with 1 (up to 2³²)

BLOB-column-number: Sequence number beginning with 1 (up to 2³²)

Use the XTFPERMIT environment variable to specify the file mode for LOB input files.

2.2.3 Specifying environment variables

Organization of this subsection

(1) Environment variables required in order to use HiRDB Dataextractor

(2) Specification of environment variables

(3) Specifying environment variables in HiRDB Dataextractor's environment variable information setup file

(4) Exception methods for specifying environment variables

(1) Environment variables required in order to use HiRDB Dataextractor

This section describes the environment variables that are required in order to use HiRDB Dataextractor. These environment variables are specified as components of the following information, depending on the facility to be used:

xtrep command executor's environment

HiRDB Dataextractor's environment variable information setup file

Table 2-6 shows where to specify the HiRDB Dataextractor environment variables. Table 2-7 lists the environment variables required in order to use HiRDB Dataextractor.

Table 2-6 Location of HiRDB Dataextractor environment variables

Item | Source system | Target system | File creation system
Importing extracted data into HiRDB or creating a file | Using XDM/XT to import data into XDM/RD or create a sequential dataset
Location of environment variables | xtrep command executor's environment | HiRDB Dataextractor's environment variable information setup file

Table 2-7 Environment variables required in order to use HiRDB Dataextractor

Environment variable | Type
XDM/XT linkage | HiRDB Dataextractor linkage
Source system | Target system | File creation system | Source system | Target system | File creation system
EXT1 | EXT2 | EXT1 | EXT2
XTHOST | -- | -- | -- | -- | O | O | -- | --
XTXHOST | -- | -- | -- | -- | O | O | -- | --
XTPORTNO | -- | -- | O | -- | O | O | -- | --
XTFESHOST | -- | -- | O | -- | -- | -- | -- | --
XTOPNWTIME | -- | -- | O | -- | -- | -- | O | --
XTWRTWTIME | -- | -- | O | -- | -- | -- | O | --
XTTCPWTIME | O | O | O | O | O | O | O | O
XTOSIWTIME | O | O | O | O | -- | -- | -- | --
XTTMPDIR | -- | -- | O | O | -- | -- | O | O
XTDPERMIT | -- | -- | O | O | -- | -- | O | O
XTFPERMIT | -- | -- | O | O | -- | -- | O | O
XTSTRETRY | O² | O² | O² | O² | -- | -- | -- | --
XTLOGNAME | O² | O² | O² | O² | O | O | O² | O²
XTLOGRETRY | O² | O² | O² | O² | O | O | O² | O²
XTTEMPNAM | O² | O² | O² | O² | O | O | O² | O²
XTLOBBUFSIZE | O | O | -- | -- | O | O | -- | --
XTFILESIZE | -- | -- | -- | -- | O | O | -- | --
XTLOBKIND | -- | -- | -- | -- | O | O | -- | --
XTERRLEVEL | O | O | -- | -- | O | O | -- | --
XTPDCFPATH | -- | -- | O | -- | -- | -- | O | --
XTPDCFxxxx | -- | -- | O | -- | -- | -- | O | --
XTARRAY | -- | -- | -- | -- | O | O | -- | --
XTTRCDIR | O | O | O | O | O | O | O | O
XTCNDSKP | -- | -- | -- | -- | O | O | -- | --
XTEXTRACTDB | O | R | -- | -- | -- | -- | -- | --
XTNLDFLT | -- | -- | -- | -- | O | O | -- | --
XTORAUSER | -- | R | -- | -- | -- | R | -- | --
XTSQL | -- | -- | -- | -- | O | -- | -- | --
XTLOCALE | -- | -- | -- | -- | O | O | O | O
XTUNDEF | -- | -- | -- | -- | -- | -- | O | O
XTCLMxxxx | O | O | -- | -- | -- | -- | -- | --
XTWHExxxx | O | O | -- | -- | -- | -- | -- | --
XTLCKxxxx | O | O | -- | -- | -- | -- | -- | --
XTTBLxxxx | O | O | -- | -- | -- | -- | -- | --
XTLPRMxxxx | -- | -- | O | -- | -- | -- | O | --
XTPDSRxxxx | -- | -- | O | -- | -- | -- | O | --
TZ | O² | O² | O² | O² | O | O | O² | O²
XTPCHKTIME | O² | O² | O² | O² | O | O | O² | O²
PDDIR | R | -- | R | -- | R | -- | R | --
PDCONFPATH | R | -- | R | -- | R | -- | R | --
PDUSER¹ | R | -- | R | -- | R | -- | R | --
PDHOST¹ | O³ | -- | -- | -- | O | -- | -- | --
PDNAMEPORT¹ | O³ | -- | -- | -- | R | -- | -- | --
PDBLKF¹ | O | -- | -- | -- | O | -- | -- | --
PDFESHOST¹ | O | -- | -- | -- | O | -- | -- | --
PDSERVICEGRP¹ | O | -- | -- | -- | O | -- | -- | --
PDCLTPATH¹ | O | -- | -- | -- | O | -- | -- | --
PDSQLTRACE¹ | O | -- | -- | -- | O | -- | -- | --
ORACLE environment variables | -- | R | -- | -- | -- | R | -- | --
PATH | -- | -- | -- | -- | R | R | -- | --
SHLIB_PATH | -- | -- | -- | -- | O | O | -- | --
LD_LIBRARY_PATH | O | -- | O | -- | O | -- | O | --
LIBPATH | O | -- | O | -- | O | -- | O | --
LANG | O | O | O | O | O | O | O | O

R: Required.

O: Optional.

XDM/XT linkage: XDM/XT is linked for data extraction or import.

HiRDB Dataextractor linkage: HiRDB Dataextractor is linked to another HiRDB Dataextractor for data extraction or import.

EXT1: HiRDB source system.

EXT2: ORACLE source system.

¹ HiRDB client's environment variable. For details about the specification, see the HiRDB UAP Development Guide.

² The specification of this environment variable depends on the HiRDB Dataextractor startup method; for details, see (4) in 2.2.3 Specifying environment variables.

³ Always specify when the RDBDEF statement, which is a JXUMCTL control statement of XDM/XT, is specified.

(2) Specification of environment variables

The following explains how to specify each of the environment variables.

XTHOST

Specify on the source system the name of the host to which data is to be sent. You can specify the FQDN instead of the host name. This environment variable is assumed when the -h option is omitted from the xtrep command.

To import extracted data into a table, specify the name of the host that contains the following server:

HiRDB/Single Server
Single server (SDS)

HiRDB/Parallel Server
System manager (MGR)

To create a file from extracted data, specify the name of the host at which the file is to be created.

Note

If the hosts on the source and target systems use different LANs, you must specify the XTXHOST environment variable. The XTHOST and XTXHOST environment variables are mutually exclusive.

If the target HiRDB uses the system switchover facility, specify the name of the host that inherits the IP address.

XTXHOST

Specify on the source system the name of the host on the data target system. You can specify the FQDN instead of the host name. If the hosts on the source and target systems use different LANs, you must specify this environment variable.

This environment variable is assumed when the -H option is omitted from the xtrep command.

Specify the name of the host on the data target system that contains the following server(s):

HiRDB/Single Server
Single server (SDS)

HiRDB/Parallel Server
System manager (MGR) and server to which data is to be sent (front-end server (FES) or back-end server (BES))

For details about the specification, see the -H option in 4.2.2 xtrep command.

Note

The XTXHOST and XTHOST environment variables are mutually exclusive.

If the target HiRDB uses the system switchover facility, specify the name of the host that inherits the IP address.

XTPORTNO

~ <unsigned integer> ((1025-65535))

Specify on the source system the port number to be used by the HiRDB Dataextractor on the data import or file creation system.

This environment variable is assumed when the -p option is omitted from the xtrep command.

On the target system, to transfer data from XDM/XT to a specified server using the OSI protocol, use this environment variable to specify the port number of the HiRDB Dataextractor running at the host where the target HiRDB's system manager is located. This port number must have been assigned (by the user) for HiRDB Dataextractor with /etc/services.

XTFESHOST {STANDARD|HIRDB}

Specify on the target system the type of the HiRDB server's host name (as specified in the pdunit -x option in the HiRDB system common definitions). This specification is required only when the OSI protocol is used, the target server (front-end server or back-end server) and XDM/XT are connected with the OSI protocol, and the system manager and XDM/XT are not connected with the OSI protocol.

STANDARD: Use the default host name for the server.

HIRDB: Use another host name for the server.

XTOPNWTIME

~ <unsigned integer> ((60-65535)) <<60>>

Specify on the target system the input file data write monitoring time (in seconds). This value is used in monitoring the amount of time used for the following processing:

Time required for pdload to start loading data after HiRDB Dataextractor has issued an internal call to pdload

The monitoring time must be greater than HiRDB's lock-release wait time; for details about the lock-release wait time, see the HiRDB System Definition manual. HiRDB Dataextractor does not monitor the time when writing data into an output file (-o or -O option is specified in the xtrep command).

XTWRTWTIME

~ <unsigned integer> ((600-65535)) <<600>>

Specify on the target system the input file data write monitoring time (in seconds). This environment variable is specified in case HiRDB Dataextractor terminates with an error while importing data into HiRDB in the addition mode due to a timeout because too many data items have been registered. This value is used in monitoring the amount of time used for the following processing:

Time required for pdload to load data after HiRDB Dataextractor has written data into an input file

HiRDB Dataextractor does not monitor the time when writing data into an output file (-o or -O option is specified in the xtrep command).

XTTCPWTIME

~ <unsigned integer> ((60-65535))

When the TCP/IP protocol is being used, specify the response monitoring time during data transfer (in seconds). If you omit this environment variable, HiRDB Dataextractor will not monitor for responses.

Notes

If the specified value is too small, HiRDB Dataextractor may erroneously assume a communication error and terminate processing.

In the case of Windows, HiRDB Dataextractor monitors the time only during a data receive operation, not during a data send operation.

XTOSIWTIME

~ <unsigned integer> ((60-65535)) <<3600>>

When the OSI protocol is being used, specify the response monitoring time during data transfer (in seconds).

Note

If the specified value is too small, HiRDB Dataextractor may erroneously assume a communication error and terminate processing.

XTTMPDIR

Specify on the import or file creation system the name of the directory in which output files are to be created and the name of the LOB input file storage directory, expressed as an absolute pathname. If you omit this environment variable, HiRDB Dataextractor assumes /opt/HIRDBXT/spool.

XTDPERMIT

~ <unsigned integer> ((1-777)) <<700>>

Specify on the import or file creation system the file mode for the LOB input file storage directory, expressed as an octal number.

Specify this environment variable when the user executing HiRDB Dataextractor is not the HiRDB administrator and file creation is to be followed by data import into a HiRDB database.

If this environment variable is omitted, pdload called by HiRDB Dataextractor will terminate with an error because it does not have the privilege to read the created file.

Note

When umask(2) is specified, the actual file mode depends on the umask(2) specification.

XTFPERMIT

~ <unsigned integer> ((1-777)) <<600>>

Specify on the import or file creation system the file mode for the output file and LOB input files, expressed as an octal number.

Specify this environment variable when the user executing HiRDB Dataextractor is not the HiRDB administrator and file creation is to be followed by data import into a HiRDB database.

If this environment variable is omitted, pdload called by HiRDB Dataextractor will terminate with an error because it does not have the privilege to read the created file.

Note

If umask(2) is specified, the actual file mode depends on the umask(2) specification.

XTSTRETRY

~ <unsigned integer> ((1-360))

Specify the maximum number of retries for executing the xtstart command if the program required for OSI communication (XNF) is not active. If XNF is not active during execution of the xtstart command and this environment variable is specified, HiRDB Dataextractor retries the xtstart command until XNF starts, up to the number of times set in this environment variable. The retries are executed at 10-second intervals. If you omit this environment variable, the xtstart command will not be retried.

XTLOGNAME

Specify the absolute pathname of the file to which log messages are to be output. For the file naming conventions, see the applicable OS manual. Do not enclose the filename in quotation marks (").

This environment variable is effective only if the value set in the XTTEMPNAM environment variable is 1.

XTLOGRETRY

~ <unsigned integer> ((0-100)) <<20>>

Specify the number of retries that may be attempted when message output to syslog fails.

XTTEMPNAM {0|1}

Specify the method for determining the names of files created by HiRDB Dataextractor:

0: Use the tempnam function to determine filenames

1: Use the date and time to determine filenames

If you omit this environment variable, 1 is assumed.

For details about the tempnam function, see the applicable OS manual.

XTLOBBUFSIZE

~ <unsigned integer> ((1-2147483647)) <<BLOB column definition length>>

Specify the buffer size for extracting columns with the BLOB or BINARY attribute at the source or for importing ORACLE data with the BLOB or BINARY attribute to the target.

If the definition length does not match the actual LOB data length, you can save buffer space by specifying the actual data length in this environment variable, because HiRDB Dataextractor uses a buffer of the size specified here.

If the specified value is greater than the BLOB or BINARY column definition length, HiRDB Dataextractor ignores this specification and uses the BLOB column definition length.

The value specified in this environment variable is effective for all BLOB and BINARY columns in a table subject to extraction.

Notes

To extract a column of the SGMLTEXT type, you must specify this environment variable. If you omit this environment variable in such a case, HiRDB Dataextractor will issue the JXU7002E message and terminate with return code 12. The value of this environment variable must be the maximum length of the original text data subject to extraction.

To extract ORACLE's LONG, LONG RAW, BLOB, CLOB, NCLOB, or BFILE columns, you must specify this environment variable. If you omit this environment variable in this case, HiRDB Dataextractor may issue the JXU7002E message and terminate with return code 12. The value of this environment variable must be the maximum length of the real data subject to extraction.

If the extracted data exceeds the specified value, HiRDB Dataextractor executes postprocessing according to the specification of the XTERRLEVEL environment variable.

The following is an example of determining the buffer size for real data (for HiRDB):

This example outputs the maximum length of real data to the size output file.

Column name specification file for BLOB type (clm):

max(length(column-name))

Column name specification file for SGMLTEXT type (clm):

max(length(extracts(column-name)))

xtrep command:

xtrep -R dat -o size -s clm table-name

Example of the XTLOBBUFSIZE environment variable

This example specifies the real data length (2,048 bytes) as the buffer size for the following data definition:

Table definition

Table A
Column A1 | Column A2 | Column A3
BLOB (1K) | SGMLTEXT | BLOB (3K)

Definition lengths

Column A1: 1,024 bytes

Column A2: 2,147,483,647 bytes

Column A3: 3,072 bytes

Specification of environment variable

setenv XTLOBBUFSIZE=2048

Buffer size

When the above specification is made, the buffer sizes that are actually allocated are as follows:

Column A1: 1,024 bytes

Column A2: 2,048 bytes

Column A3: 2,048 bytes

Note

If real data in column A2 or A3 exceeds 2,048 bytes with these settings, the data will be truncated.

XTFILESIZE

~ <unsigned integer> ((8192-2147483647))

Specify on the source system the maximum output file size.

If you are creating a file during data import or you are creating a file during file creation, and there is too much data to be stored in a single file, you can divide the data into multiple output files by specifying a maximum output file size in this environment variable. HiRDB Dataextractor also saves data in multiple output files when multiple file names are specified in the -o or -O option of the xtrep command.

HiRDB Dataextractor creates each output file so that each line fits within the specified size. For details about the names of these output files when this environment variable is specified, see (3) File naming conventions in 2.2.2 Installing HiRDB Dataextractor.

Notes

If you omit this environment variable and the size of an output file exceeds 2 GB (gigabytes) or the partition used to create the file becomes full, an error results and HiRDB Dataextractor issues the JXU7002E message (file write error).

You must specify in this environment variable a value that is at least the size of a line of extracted data. If the actual data is larger than the value specified here, an error results and HiRDB Dataextractor issues the JXU7209E message (file write error).

You can use this environment variable only if the HiRDB Dataextractor on the import or file creation system also supports this function. If HiRDB Dataextractor does not support this function, an error results and HiRDB Dataextractor issues the JXU7001E message on the import or file creation system.

Note that the size of a row of extracted data depends on the XTNLDFLT environment value. For details about the data format, see (4) Output file in 4.2.4 Contents of files specified with the xtrep command, and A. Memory and File Requirements.

XTLOBKIND {0|1}

At the source system, specify the format of the data for BLOB-type columns (LOB data) to import it into a HiRDB table. This specification can improve performance because it enables BLOB-type LOB data to be stored in the same file as non-LOB data.

If 2 is specified in the XTNLDFLT environment variable, this environment variable serves no purpose, because the input data format specified in the -W option of the database load utility (pdload) is used when data is imported into a HiRDB table or a binary-format file is created.

0: Output BLOB-type LOB data to separate files (LOB input files)

1: Output BLOB-type LOB data to the same files as non-LOB data

Table 2-8 shows the format of the data that is created if 0 is specified in the XTLOBKIND environment variable, and Table 2-9 shows the format of the data that is created if 1 is specified in the XTLOBKIND environment variable.

Table 2-8 Format of the data to be created when 0 is specified in the XTLOBKIND environment variable

Source system | Import or file creation system | Column attribute | Format of data with BLOB attribute | Value of -k option in pdload | Remarks
ADT | BLOB | ADT | BLOB
HiRDB or ORACLE | Import to HiRDB table | No | No | N/A | N/A | N/A | N/A
Yes | N/A | 1. | f
Yes | No | 2. | N/A | v
Yes | 2. | 1.
Creation of binary file | No | No | N/A | N/A | N/A | N/A
Yes | N/A | 1.
Yes | No | 1.#1 | N/A | #2
Yes | 1.#1 | 1.
Creation of DAT file | No | No | N/A | N/A | N/A | N/A
Yes | N/A | 1.
Yes | No | 1. | N/A
Yes | 1. | 1.

ADT: Abstract Data Type

Format of BLOB-attribute data:

Create a BLOB-attribute column in a separate file (input file or LOB input file).

Create in one file (input file only).

N/A: Not applicable

#1

This becomes 2. if SGMLTEXT is specified in the import information file.

#2

If you are extracting data from a table containing SGMLTEXT in order to create a file, verify that SGMLTEXT is specified with respect to the import information file. If this specification is omitted and the created file is used with pdload to import data into a HiRDB table, the results may be unpredictable.

Table 2-9 Format of the data to be created when 1 is specified in the XTLOBKIND environment variable

Source system | Import or file creation system | Column attribute | Format of data with BLOB attribute | Value of -k option in pdload | Remarks
ADT | BLOB | ADT | BLOB
HiRDB or ORACLE | Import to HiRDB table | No | No | N/A | N/A | N/A | N/A
Yes | N/A | 2. | d
Yes | No | 2. | N/A
Yes | 2. | 2.
Creation of binary file | No | No | N/A | N/A | N/A | N/A
Yes | N/A | 2.
Yes | No | 2. | N/A | N/A | *
Yes | 2. | 2.
Creation of DAT file | No | No | N/A | N/A | N/A | Specification not permitted
Yes
Yes | No
Yes

ADT: Abstract Data Type

Format of data with BLOB attribute:

Create a BLOB-attribute column in a separate file (input file or LOB input file)

Create in one file (input file only)

N/A: Not applicable.

* If you are extracting data from a table containing SGMLTEXT in order to create a file, verify that SGMLTEXT is specified with respect to the import information file. If this specification is omitted and the created file is used with pdload to import data into a HiRDB table, the results may be unpredictable.

Relationship between the value of the XTLOBKIND environment variable and the number of files to be created

Table 2-10 shows the relationship between the value of the XTLOBKIND environment variable and the number of files to be created.

Table 2-10 Relationship between the value of the XTLOBKIND environment variable and the number of files to be created

Specified value | File split¹ | Number of output files (pdload input files) | Example of data status²
Input files | LOB input files
0 | No | 1 | Number of data items | 1.
Yes | Number of split files | Number of data items | 2.
1 | No | 1 | 0 | 3.
Yes | Number of split files | 0 | 4.

¹ The output file can be divided if specified in the -o or -O option in the xtrep command or in the XTFILESIZE environment variable.

² The following are examples of data status:

Data format for BLOB columns when XTLOBKIND 1 is specified

The following explains the data format for columns of the BLOB type (hereafter called BLOB) and abstract data type with the BLOB attribute (hereafter called ADT (BLOB)) when 1 is specified in the XTLOBKIND environment variable:

The data size fields for BLOB and ADT (BLOB) columns are output with other columns in the order of their definition.

The data fields of ADT (BLOB) columns are output at the end of the row data in the order of their definition.

The BLOB data fields are output at the end of the row data in the order of their definition.
If the table to be imported into HiRDB contains both BLOB and ADT (BLOB), the BLOB data fields are output following the ADT (BLOB) data fields.

If data is the null value, -1 is set in the size field for BLOB and ADT (BLOB). In this case, the data fields are not output.

In the case of zero-bytes data, 0 is set in the size field for BLOB and ADT (BLOB). In this case, the data fields are not output.

Example of data creation when XTLOBKIND is specified

The following is an example of data creation when the XTLOBKIND environment variable is specified:

XTERRLEVEL {0|1}

Specify on the source system the HiRDB Dataextractor processing to be performed in the event of an error during data extraction.

0: If an error occurs, output the JXU7208I message, resume processing, and terminate with return code 4.

1: If an error occurs, output the JXU7208E message and terminate with return code 12.

Notes

The following errors are subject to the setting in this environment variable:
- Data truncation
- Overflow
For overflow to be detected, you must have specified Y in the pd_overflow_suppress operand in the HiRDB system common definition.

Specify 1 in this environment variable in the following cases:
- When a column that has the SGMLTEXT data type is extracted
- When data is imported into a table in which truncation may occur

XTPDCFPATH

~ <pathname>

Specify on the target system the absolute pathname of the control information file that contains the idxwork, index, and lobmid statements for HiRDB's database load utility (pdload). This environment variable enables you to specify the destination of index information files and LOB middle files that are created by HiRDB's database load utility.

Notes

If this environment variable and the XTPDCFxxxx environment variable are omitted, pdload creates an index information file and LOB intermediate file under /tmp. If the target table contains indexes or columns of the BLOB type, temporary files are output under /tmp according to the amount of data. If there is not enough space in /tmp, the entire system may be affected adversely.

If the target table contains no indexes but the specified control information file contains the idxwork or index statement, or if the target table contains no BLOB column but the specified control information file contains the lobmid statement, pdload results in an error. In such a case, use the XTPDCFxxxx environment variable. Create a control information file for each target table, and specify the XTPDCFxxxx environment variable. During execution of HiRDB Dataextractor, specify the XTPDCFxxxx environment variable in the xtrep command that corresponds to the table on the target system in order to select the control information file to be used.

Specification example

Environment variable information setup file

     :
     :
set XTPDCFPATH=/HIRDBXT/conf/xtpdcf
     :
     :

/HIRDBXT/conf/xtpdcf

idxwork /hd001/idxwork
lobmid /hd002/tmp

XTPDCFxxxx

~ <pathname>

Specify on the target system the absolute pathname of the control information file that contains the idxwork, index, or lobmid statement for HiRDB's database load utility (pdload). This environment variable enables you to specify the destination of index information files and LOB middle files that are created by HiRDB's database load utility.

For xxxx, specify any character string (0 to 4 alphanumeric characters).

When you specify the name of this environment variable in the xtrep command's -I option, pdload stores data using the control information file specified in this environment variable.

Notes

If you omit this environment variable or the XTPDCFPATH environment variable, pdload creates the index information file and LOB middle file under /tmp. If the target table contains indexes or columns of the BLOB type, temporary files are output under /tmp according to the amount of data. If there is not enough space in /tmp, the entire system may be affected adversely.

If the target table contains no indexes but the specified control information file contains the idxwork or index statement, or if the target table contains no BLOB column but the specified control information file contains the lobmid statement, pdload results in an error. In such a case, use this environment variable to specify the control information file to be used by pdload. Create a control information file for each target table, and specify this environment variable. During execution of HiRDB Dataextractor, specify the XTPDCFxxxx environment variable in the xtrep command that corresponds to the table on the target system in order to select the control information file to be used.

XTARRAY {FF|FV|VV} [,{C|E}]

Specify the data format (FF, FV, or VV) and null value handling method (C or E) for output of repetition columns to a file.

Specify this environment variable to specify the data format or null value handling method for each table. To specify this information for each column, use the null value information file that is specified in the -v option of the xtrep command. If you specify both this environment variable and a null value information file, the null value information file takes precedence.

If you omit this environment variable, HiRDB Dataextractor assumes VV and C.

If 2 is specified in the XTNLDFLT environment variable, this environment variable is ignored and VV and C are assumed when data is imported into a HiRDB table or when a binary-format file is created.

For details about the specification of data format and null value handling method for repetition columns, see (6) in 3.1.1 Extracting selected data.

Data format

FF

The number of elements is not at the beginning of a column and there is data for all column elements.

FV

The number of elements is at the beginning of a column and there is data for all column elements.

VV

The number of elements is at the beginning of a column and there are as many data items as there are elements.

Null value handling method

C

When there is no data for any element, handle the entire column as the null value.

E

When there is no data for any element, handle each element as a null value.

XTTRCDIR

~ <pathname>

Specify the absolute pathname of the directory for the module trace file and core file that are created by HiRDB Dataextractor. The following file and directory are subject to this environment variable setting:

Module trace file

Directory for storing core

If you omit this environment variable, HiRDB Dataextractor assumes /opt/HIRDBXT/dump.

Note

You should delete the files under /opt/HIRDBXT/dump periodically while HiRDB Dataextractor is stopped.

XTCNDSKP~ {0|1} <<0>>

Specify whether or not transfer data is to be compressed. If either of the following conditions is satisfied, you should not compress transfer data (in order to reduce processing time):

Communication performance is better than your machine performance

Transfer data's compression rate is low (there are not many consecutive identical codes)

0: Compress transfer data.

1: Do not compress transfer data.

XTEXTRACTDB

Specify the type of database that is to be subject to extraction.

oracle: ORACLE database

hirdb: HiRDB table

ORACLE environment variables

Define the ORACLE environment variables required in order to extract from ORACLE databases; for the names of the applicable environment variables and their values, see the ORACLE manual.

XTNLDFLT ~{0|1|2}

Specify the method to be used to import the null value when data is imported into a HiRDB table or file.

0: When a null value information file is omitted (-v option is omitted) or an assumed value is used as the default null value for a column that is not specified in the null value information file.

Specify this value if the value to be assumed is not used as real data.

For details about default values that are assumed to be null values, see Table 4-13 Null-value information file specification rules (applicable to data extraction from a HiRDB table).

1: When a null value information file is omitted (-v option is omitted) or an assumed value is used as the default null value for a column that is not specified in the null value information file.

Specify this value for the following data types if real data uses the default value that is assumed when the value of this environment variable is 0:

DECIMAL

DATE

INTERVAL YEAR TO DAY

TIME

INTERVAL HOUR TO SECOND

TIMESTAMP

For details about default values that are assumed to be null values, see Table 4-13 Null-value information file specification rules (applicable to data extraction from a HiRDB table).

2: The null value is to be imported as is without using the default null value.

Specify this value if real data uses the default value that is assumed when the value of this environment variable is 0 or 1. Note that when this value is specified, the XTLOBKIND environment variable is ignored.

The following table shows the combinations of this environment variable and the NOT NULL constraint for columns in the source and target tables:

NOT NULL constraint | XTNDFLT environment variable
Source table | Target table | 0 | 1 | 2⁵
NULL | NULL | Y¹ | Y¹ | Y
NOT NULL | Y² | N³ | N⁴
NOT NULL | NULL | -- | -- | --
NOT NULL | -- | -- | --

Y: Can be specified.

--: Specification not required (because the source table does not contain the null value, specification of this environment variable serves no purposes).

N: Cannot be specified (if pdload is used to import data, the input data will be regarded as invalid).

¹ Real data that is the same as the default null value is treated as the null value.

² For the null value, the default null value is imported as real data.

³ If the following data types contain the null value, the input data is regarded as invalid; for any other data types, the default null value is imported as real data:

DECIMAL, DATE, INTERVAL YEAR TO DAY, TIME, INTERVAL HOUR TO SECOND, TIMESTAMP

⁴ If the source table contains the null value, the input data is regarded as invalid.

⁵ When this value is specified, the amount of data is greater than when any of the other values is specified because offset information is added to check the null values. Therefore, if the source data contains no real data that is the same as the default null value, specifying this value provides no benefits.

For details about the data format, see (4) Output file in 4.2.4 Contents of files specified with the xtrep command and A. Memory and File Requirements.

The format of output data during data import into a HiRDB table or file creation depends on this specification.

The following table shows the relationship between the value of this environment variable and the format of output data:

XTNDFLT
environment variable
Format of output data

Import to HiRDB
File format

Binary format
DAT format

0
Binary input file format supported by HiRDB's database load utility.
Same as at left
DAT input file format supported by HiRDB's database load utility.

1

2
Input file format used when the -W option is specified in HiRDB's database load utility¹.
Same as at left

¹ BLOB-type LOB data is output to the same file as non-BLOB-type data, regardless of the specification of XTLOBKIND environment variable.

Notes on specification value 1

There are HiRDB version requirements (07-00/J or later) for this specification. If the requirements are not satisfied, HiRDB's database load utility (pdload) results in an error due to invalid contents in the null value information file.

If this specification is used for the file creation (binary-format) facility and the source table contains the null value, the default null value is stored as data in the file. Note that when a file created by this facility is used, the format of the default null value is different from that of the data type (X'FF ... FF').

Notes on specification value 2

This specification is applicable only when the target or the HiRDB Dataextractor where the file is created also supports this facility. If the target or the HiRDB Dataextractor where the file is created does not support this facility, it issues the JXU7017E message, resulting in an error.

For data import into a FIX table, specify a value other than 2 because specification of 2 serves no purpose. If 2 is specified to import data into a FIX table, HiRDB Dataextractor issues the JXU7223E message, resulting in an error.

XTORAUSER

Specify the user name and password of the user who will connect to ORACLE on the source system, expressed as "user-name"/"password".

The specified user must have ORACLE's SELECT or SELECT ANY TABLE privilege for the table to be extracted. If LOCK is issued to the table to be extracted, the user must also have the LOCK ANY TABLE system privilege or object privilege.

XTSQL

Specify whether or not user-specified SQL statements may be specified when multiple HiRDB Dataextractors are linked and data is extracted from an HiRDB table or ORACLE database. For details about specifying the command, see 4.2.3 Additional data extraction and import functions.

0: Extract data from the table specified on the command line of xtrep.

1: Extract data from the table specified in the table expression specification file.

Notes

When you specify 1 in this environment variable, you must specify the following parameters; if you omit these parameters, HiRDB Dataextractor issues the JXU7307E message, resulting in an error:
-g option
-r or -R option

When you specify 1 in this environment variable, you must not specify the following parameter; if you specify this parameter, HiRDB Dataextractor issues the JXU7306E message, resulting in an error:
-w option
When you specify 1 in this environment variable, specify on the command line the name of the table expression specification file, not the name of the extraction table. If the specification is omitted, HiRDB Dataextractor issues the JXU7300E message, resulting in an error.

XTLOCALE

~ {sjis|euc|utf-8|unknown} <<unknown>>

To use the character code conversion function, specify a character code system used by both the locale and the target system:

sjis: JIS8 or Shift JIS system

euc: EUC system

utf-8: UTF-8 system

unknown: Do not convert character codes

Notes

HiRDB Dataextractor does not check the value of this environment variable against the locales supported by the OS. If the specified value is invalid, operations cannot be guaranteed.

If the character code system is UTF-8, specify utf-8 regardless of whether code conversion is used.

XTUNDEF

~ {space|sharp|hexadecimal-character-string}[,cancellation-count] <<space,100>>

To use the character code conversion function, specify the handling of undefined codes at the target system:

space: Replace with the single-byte space (0x2020).

sharp: Replace with the double-byte hash mark (#).

hexadecimal-character-string: Replace with the specified double-byte code. Specify a value that begins with 0x and consists of 4 characters in the range 0 to f.

cancellation-count ~ <unsigned integer> ((0-10000))

Specify the number of records before processing is to be cancelled after a conversion error is detected. This means that a record is counted as 1 even if multiple conversion errors are detected within that record. When 0 is specified, processing will not be cancelled.

Notes

When sharp is specified in this environment variable, the code for the double-byte hash mark (#) differs depending on the specification value for the XTLOCALE environment variable at the target system:
- sjis: 0x8194
- euc: 0xa1f4
- utf-8: 0xefbc83

If you used the XTLOCALE environment variable to specify the UTF-8 code set at the target system or the file creation system, specify the UCS2 code value corresponding to the value to be output in UTF-8 in hexadecimal-character-string.

XTCLMxxxx (xxxx: any character string)

~ <pathname> ((1-256 characters))

Specify on the source system the absolute pathname of the column name specification file.

XTWHExxxx (xxxx: any character string)

~ <pathname> ((1-256 characters))

Specify on the source system the absolute pathname of the table expression specification file.

XTLCKxxxx (xxxx: any character string)

~ <pathname> ((1-256 characters))

Specify on the source system the absolute pathname of the lock information file.

XTTBLxxxx (xxxx: any character string)

~ <path name> ((1-255 characters))

Specify at the source system the absolute path name of the table name information file. For details about the table name information file, see (7) Setting the table name information file in 2.2.4 Files required in order to use HiRDB Dataextractor.

XTLPRMxxxx (xxxx: any character string)

~ <path name> ((1-255 characters))

Specify at the target system the absolute path name of the file that contains the pdload command line information. For details about this file, see (8) Setting the pdload command line information file in 2.2.4 Files required in order to use HiRDB Dataextractor.

XTPDSRxxxx (xxxx: any character string)

~ <path name> ((1-255 characters))

Specify at the target system the absolute path name of the file that contains the pdload control information file's source statement information. For details about this file, see (9) Setting the pdload control information file's source statement information file in 2.2.4 Files required in order to use HiRDB Dataextractor.

TZ

~ <character string>

Specify the time zone for date and time information that is to be output to the error log file. Verify that this environment variable's setting is the same in both HiRDB and HiRDB Dataextractor. If the settings are different, HiRDB's and HiRDB Dataextractor's message times in the error log file and syslog may not match.

If this environment variable is omitted, the OS settings are assumed.

XTPCHKTIME

~ <unsigned integer> ((30~600)) <<180>>

Specify one of the following as the monitoring interval to be used, as appropriate to the facility being used. Specify a multiple of 30. If the specified value is not a multiple of 30, HiRDB Dataextractor rounds it up to the nearest multiple of 30.

When using a HiRDB Dataextractor-linked extraction facility:
Interval from issuance to the target system of a confirmation request to reception from the target system of a confirmation message

When using any other facility:
Interval from the start of target confirmation to reception of a target system confirmation message

PDDIR

Specify on the source system the absolute pathname of the HiRDB directory for the HiRDB running on the source system.

Specify on the target system the absolute pathname of the HiRDB directory for the HiRDB running on the target system.

PDCONFPATH

Specify on the source system the absolute pathname of the HiRDB system definition files for the HiRDB running on the source system.

Specify on the target system the absolute pathname of the HiRDB system definition files for the HiRDB running on the target system.

PDUSER

Specify on the source system the user name and password of the user who will connect to the HiRDB running on the source system, expressed as "user-name"/"password". The specified user must have HiRDB's SELECT privilege for the table to be extracted.

Specify on the target system the user name and password of the user who will connect to the HiRDB running on the target system, expressed as "user-name"/"password". The specified user must have HiRDB's INSERT privilege for the table to be imported. If existing table data is to be deleted before importing data, the user must have HiRDB's INSERT and DELETE privileges.

PDHOST

Specify on the source system the host name of the system manager for the HiRDB running on the source system.

PDNAMEPORT

Specify on the source system the port number of the HiRDB system located on the source system.

PDBLKF

Specify on the source system the number of rows for block transfer.

This environment variable may be able to reduce HiRDB's extraction time. For details, see the HiRDB UAP Development Guide.

PDFESHOST

Specify on the source system the host name of the front-end server.

PDSERVICEGRP

Specify on the source system the name of the front-end server.

PDCLTPATH

Specify on the source system a directory for storing the SQL trace file that is used to collect HiRDB's SQL trace information. If PDCLTPATH is omitted, the SQL trace file is stored in the current directory.

PDSQLTRACE

Specify this environment variable on the source system in order to collect HiRDB's SQL trace information. In this environment variable specify the size of the SQL trace file. When you extract data from HiRDB, HiRDB Dataextractor issues HiRDB SQL statements in order to perform the data extraction. If you collect SQL trace information, you can use this information in the event of a data extraction error. For details about the SQL trace file, see the HiRDB System Operation Guide.

PATH

Specify this environment variable on the source system in order to add /opt/HIRDBXT/bin.

SHLIB_PATH

In a user environment where the xtrep command is entered, or in the case of using an environment variable information setup file, specify the absolute path to the directory that contains the source HiRDB or ORACLE shared library.

If you are extracting data from an ORACLE database, specify the path to a shared library that contains 32-bit client libraries.

If the OS being used is Solaris, Linux, or AIX, this environment variable is ignored when specified.

LD_LIBRARY_PATH

~ <pathname>

In a user environment where the xtrep command is entered, or in the case of using an environment variable information setup file, specify the absolute path to the directory that contains the source HiRDB or ORACLE shared library.

If you are extracting data from an ORACLE database, specify the path to a shared library that contains 32-bit client libraries.

This environment variable is applicable only when the OS being used is Solaris or Linux.

LIBPATH

<path name>

In a user environment where the xtrep command is entered or in the case of using an environment variable information setup file, specify the absolute path to the directory that contains the source HiRDB or ORACLE shared library.

If you are extracting data from an ORACLE database, specify the path to a shared library that contains 32-bit client libraries.

This environment variable is applicable only when the OS being used is AIX.

LANG

Specify on the source system the character code set being used when HiRDB on the source system uses national character strings.

Specify on the target system the character code set being used when HiRDB on the target system uses national character strings. To import data from a mainframe database into a HiRDB database using XDM/XT, this character code set must be of the character type after conversion that is specified in XDM/XT's CONVERT JXUMCTL control statement. If a different character type is specified, the results may not be correct.

Specify on the file creation system the character code set being used when the system on the file creation system uses national character strings.

The default value is ja_JP.SJIS.

Note

When the LC_ALL or LC_* environment variable is specified, the LANG environment variable is ignored if specified, because the former takes effect. The LANG environment variable settings take effect only when the LC_ALL or LC_* environment variable is omitted.
Note that with some systems, a default value may be set for the LC_ALL or LC_* environment variable.
If you need to change the value of the LC_ALL or LC_* environment variable set by the system, specify the LC_ALL or LC_* environment variable instead of the LANG environment variable.
Take this into account when you are executing a command that requires the LANG environment variable.

When the OS being used is Windows, the LANG environment variable is ignored even if specified.

(3) Specifying environment variables in HiRDB Dataextractor's environment variable information setup file

The following shows how to specify environment variables in HiRDB Dataextractor's environment variable information setup file.

Format

set environment-variable=environment-variable-value

Rules

Specify one set statement per line.

Do not place any spaces before or after the equals sign (=).

A comment begins with the number sign (#) and ends at the end of the line.

Example

set PDDIR=/HiRDB
set PDCONFPATH=/HiRDB/conf
set PDUSER="user01"/"user01"
set LANG=ja_JP.SJIS
set XTPORTNO=20052

(4) Exception methods for specifying environment variables

This subsection describes the environment variable specification methods that are different from the normal specification method.

Table 2-11 shows the exception methods for specifying environment variables.

Table 2-11 Exception methods for specifying environment variables

Protocol
OS being used
HiRDB Dataextractor's startup method
Environment variable specification method
Remarks

TCP/IP
HP-UX
Solaris
Linux
AIX
Automatic startup by inetd
Specify in inetd.conf.
See specification example 1.

Windows
Automatic startup by service
Specify in hirdbxt.ini.
N/A

OSI
HP-UX
Automatic startup by localrc or rc
Specify in localrc or rc
See specification example 2.

Manual startup using the xtstart command
Specify setenv in the executing user environment.
See specification example 3.

Windows
Solaris
Linux
AIX
N/A
N/A
N/A

Specification example 1

Specifying /etc/inetd.conf:

hirdbxt stream tcp nowait user01 /bin/env env XTTEMPNAM=0
/opt/HIRDBXT/bin/pxtcntl /usr/home/user01/xtenv1

Note

Specify the entire coding in one line. If you specify an environment variable, do not specify pxtcntl.

Specification example 2

Specifying /etc/localrc:

/bin/env XTTEMPNAM=0 /opt/HIRDBXT/bin/xtstart
/opt/HIRDBXT/HIRDB_conf /opt/HIRDBXT/OSI_conf

Note

Specify the entire coding in one line.

Specification example 3

Specifying the xtstart command:

setenv XTTEMPNAM=0
/opt/HIRDBXT/bin/xtstart /opt/HIRDBXT/HIRDB_conf /opt/HIRDBXT/OSI_conf

Note

Send one line at a time.

Note

The environment variable specified by the exception method is underlined.

2.2.4 Files required in order to use HiRDB Dataextractor

This section describes the files that are required in order to use HiRDB Dataextractor. The files to be specified depend on the facility to be executed and the protocol to be used. Table 2-12 lists the files that are required in order to use HiRDB Dataextractor.

These files are specified at the host where HiRDB Dataextractor is installed. For details, see Table 2-2 Host used to install HiRDB Dataextractor.

Table 2-12 Files required in order to use HiRDB Dataextractor

Filename
Description
Type

Source system
Target system
File creation system

Extractor
XDM/XT
Extractor
XDM/XT¹

HiRDB Dataextractor's environment variable information setup file
(any file name)
Specifies HiRDB Dataextractor's environment variables.
--
R
R
R
R

/etc/services²
Specifies the port number.
--
R TCP
R TCP
R TCP
R TCP

/etc/inetd.conf²
Specifies HiRDB Dataextractor startup.
--
R TCP
R TCP
R TCP
R TCP

xtstart command execution file (any file name)
Specifies HiRDB Dataextractor startup.
--
O OSI
--
O OSI
O OSI

Communication configuration definition information file
(any file name)
Specifies communication configuration definitions.
--
R OSI
--
R OSI
R OSI

/etc/hosts
Specifies the target host name.
R TCP
--
--
--
--

Column name specification file
Table expression specification file
(any file name)
Specify extraction conditions.
For details, see 4.2.2 xtrep command and 5.1.2 xtrepO command.
O
O
--
--
--

Table name information file
(any file name)
Specifies the table expression up to the WHERE clause in the SELECT statement.
--
O
--
--
--

Null value information file
(any file name)
Specifies the default null value.
For details, see 4.2.2 xtrep command and 5.1.2 xtrepO command.
O
--
--
--
--

Lock information file
(any file name)
Specifies lock information during data extraction.
For details, see 5.1.2 xtrepO command.
O
O
--
--
--

Import information file
(any file name)
Specifies column information and data type for data type conversion.
For details, see 5.1.2 xtrepO command.
O
--
--
--
--

SQL trace file
Collects SQL trace information.
For details, see the PDCLTPATH environment variable in 2.2.3 Specifying environment variables.
O
O
--
--
--

pdload command line information file
(any file name)
Sets the HiRDB database load utility's (pdload) command line parameters.
--
--
O
O
--

pdload control information file's source statement information file
(any file name)
Sets the source statement that is specified in the control information file, which is a parameter of the HiRDB database load utility (pdload).
--
--
O
O
--

R: Required.

O: Optional.

--: Not required.

TCP: Specify when the TCP/IP protocol is used.

OSI: Specify when the OSI protocol is used.

Extractor: Linking HiRDB Dataextractor to extract and import data

XDM/XT: Using XDM/XT to extract data, import data, or create sequential datasets between a mainframe database and HiRDB

¹ TCP/IP is used to establish communication between the target server and the system manager when all three of the following conditions are satisfied: the OSI protocol is being used; the OSI protocol is used to connect the target server (front-end server or back-end server) and XDM/XT; and the system manager and XDM/XT are not connected with the OSI protocol. Therefore, specify the files used for TCP/IP (/etc/services and /etc/linetd.conf) for the system manager even if the OSI protocol is used. There is no need to specify the files used for the OSI protocol (/etc/localrc and communication configuration definition information file) for the system manager.

² File name when the OS being used is UNIX. For details about the file name when the OS being used is Windows, see B. Functional Differences with Windows.

Organization of this subsection

(1) Specifying HiRDB Dataextractor's environment variable information setup file

(2) Specifying /etc/services

(3) Specifying /etc/inetd.conf

(4) Specifying the xtstart command execution shell

(5) Specifying the communication configuration definition information file

(6) Specifying /etc/hosts

(7) Setting the table name information file

(8) Setting the pdload command line information file

(9) Setting the pdload control information file's source statement information file

(1) Specifying HiRDB Dataextractor's environment variable information setup file

When the OS being used is UNIX, specify HiRDB Dataextractor's environment variable information setup file; for details, see 2.2.3 Specifying environment variables.

When the OS being used is Windows, see B. Functional Differences with Windows.

(2) Specifying /etc/services

When the OS being used is UNIX, and the TCP/IP protocol is used, you must specify your HiRDB Dataextractor's service name and port number in /etc/services.

For the port number, specify a number that is unique within the network and that is not being used by any other service.

When the OS being used is Windows, see B. Functional Differences with Windows.

The following is an example of an entry to be registered.

/etc/services

# @(#) services  1.2  30/06/95
#
#UNIX specific services, Internet style
ftp   21/tcp
               :
               :
hirdbxt 20052/tcp  #HiRDB Dataextractor...added

(3) Specifying /etc/inetd.conf

When the OS being used is UNIX and the TCP/IP protocol is used, HiRDB Dataextractor is started from the /etc/inetd.conf configuration file. Therefore, you must specify information about HiRDB Dataextractor in /etc/inetd.conf.

If you modify the contents of /etc/inetd.conf, either you must restart the machine or the superuser must issue a signal.

When the OS being used is Windows, the specification of /etc/inetd.conf is unnecessary.

Table 2-13 shows the information to be specified in /etc/inetd.conf.

Table 2-13 Information to be specified in /etc/inetd.conf

Field name
Information to be specified

service name
HiRDB Dataextractor's service name that was specified in the /etc/services file. (Optional)

socket type
stream (Fixed)

Protocol
tcp (Fixed)

wait/nowait
nowait (Fixed)

User
UNIX login user name (Optional)*

server program
/opt/HIRDBXT/bin/pxtcntl (Fixed)

server program arguments
Argument 1: pxtcntl (Fixed)
Argument 2: Absolute pathname of the environment variable information setup file

* The specified user can start HiRDB Dataextractor. Note the following:

If the specified user is not a superuser and an error occurs in HiRDB Dataextractor, a core dump will not be output.

In the case of file creation from extracted data, if the file to be created (including a LOB input file) already exists, the user must have the write privilege. You can specify the file mode for the created file with the XTFPERMIT and XTDPERMIT environment variables. For details about how to specify the environment variables, see (2) in 2.2.3 Specifying environment variables.

If HiRDB Dataextractor is linked with XDM/XT, and data is extracted from an ORACLE database, the user must be registered in ORACLE.

Specification example of /etc/inetd.conf

hirdbxt stream tcp nowait user01
       /opt/HIRDBXT/bin/pxtcntl
       pxtcntl /usr/home/user01/xtenv1

Note

Specify this information in one line.

Example of issuing a signal when /etc/inetd.conf is modified

kill -HUP inetd-process-ID

(4) Specifying the xtstart command execution shell

When you use the OSI protocol to start HiRDB Dataextractor automatically, you must specify the xtstart command execution shell. For details about how to specify the xtstart command execution shell, see (1)(a) Automatic startup in 6.2.2 Starting and terminating HiRDB Dataextractor when using OSI.

(5) Specifying the communication configuration definition information file

To use the OSI protocol, you must specify the information required for communication in the communication configuration definition information file. The following is the specification format:

Format

set T_selector=local-host's-T-selector-value

Rules

Specify one set statement in one line.

Each line can contain only one set statement.

Do not place any spaces before or after the equals sign (=).

A comment begins with the number sign (#) and ends at the end of the line.

T_selector=local-host's-T-selector-value

~ <hexadecimal> ((2-64 characters))

Specify the local system's T selector value, in the format x'hexadecimal-number' or X'hexadecimal-number'.

Relationship with the XNF network definitions

The following explains the relationship between the communication configuration definitions and the VOS3 XNF E2 network definitions. The local host's selector value specified in the T_selector operand of the set communication configuration definition statement corresponds to the T selector value specified in the T_SELECTOR operand of the ULE XNF E2 network definition statement.

For details about the VOS3 XNF E2 network definitions, see the VOS3 XNF E2 Network Definition manual.

(6) Specifying /etc/hosts

If the OS being used is UNIX, and the TCP/IP protocol is used, you must specify the target host name in the source system's /etc/hosts.

To import extracted data into a table, specify the name of the host at which the following server is located:

Single server for a HiRDB/Single Server

System manager for a HiRDB/Parallel Server

To create files from extracted data, specify the name of the host name at the file creation system.

If the OS being used is Windows, see B. Functional Differences with Windows.

The following is an example of an entry to be registered:

/etc/hosts
      :
      :
160.16.150.120 HOST2
      :
      :

(7) Setting the table name information file

When HiRDB Dataextractor is linked with XDM/XT and data is extracted from HiRDB, to use the function for specifying SQL statements that are to be issued, you set a table name information file in the source system, if necessary, and specify its file name in the XTTBLxxxx environment variable.

In the table name information file, specify the table expression up to the WHERE clause of the SELECT statement.

For details about specifying table expressions in the SELECT statement, see the HiRDB SQL Reference manual.

(8) Setting the pdload command line information file

To use the function for specifying parameters of the HiRDB database load utility (pdload) when data is imported into a HiRDB table, you set a pdload command line information file in the target system, if necessary, and specify its file name in the XTLPRMxxxx environment variable.

In the pdload command line information file, specify the pdload command line parameters. You must ensure that none of the parameters listed below is specified; if any of these parameters is specified, operations cannot be guaranteed:

Target table name (authorization identifier, table identifier)

Control information file name

-b option (for entering binary-format data)

-k option (BLOB data format)

-v option (null value information)

-w option (for entering binary-format data created by the database reorganization utility)

-c option (information about a column structure information file)

For details about the command line parameters, see the HiRDB Command Reference manual.

(9) Setting the pdload control information file's source statement information file

To use the function for specifying pdload parameters when data is imported into a HiRDB table, you set the pdload control information file's source statement information file in the target system, if necessary, and specify its file name in the XTPDSxxxx environment variable.

In the pdload control information file's source statement information file, specify the source statements that are specified in the control information file, which is a parameter of pdload. You must ensure that none of the parameters listed below is specified; if any of these parameters is specified, operations cannot be guaranteed:

RDAREA name

Server name, host name

Input file name

Error information file name

2.3 Preparations before execution

This section describes the preparations for tables and data transfer that must be performed before you can execute HiRDB Dataextractor.

Organization of this section

2.3.1 Preparing tables

2.3.2 Preparing for data transfer

2.3.1 Preparing tables

Before you can execute HiRDB Dataextractor, you must prepare a HiRDB table into which extracted data is to be imported. The following definitions are required for such a table:

CREATE SCHEMA (schema definition)

CREATE TABLE (table definition)

CREATE INDEX (index definition)

GRANT INSERT (INSERT privilege definition)

GRANT DELETE (DELETE privilege definition)

For details about these definitions, see the HiRDB SQL Reference manual.

When you define a table, you must pay attention to the range and order of the data that will be extracted by HiRDB Dataextractor. You must also consider the type of data manipulations that may be performed on the target system.

2.3.2 Preparing for data transfer

Organization of this subsection

(1) Extracting data from HiRDB or ORACLE and then importing it into HiRDB or creating files

(2) Using XDM/XT to extract or import data between a mainframe database and a HiRDB or ORACLE database or to create files from a mainframe database

(1) Extracting data from HiRDB or ORACLE and then importing it into HiRDB or creating files

To extract data from a HiRDB or ORACLE database and then import it into a HiRDB database or create files, you must use the TCP/IP communication protocol. This requires the following specifications:

Name of the host on the import or file creation system (register this host name in /etc/hosts/ on the source system)

HiRDB Dataextractor's port number on the import or file creation system (register this port number in /etc/services on the target system or file creation system)

For details about these specifications, see 2.2.4 Files required in order to use HiRDB Dataextractor.

(2) Using XDM/XT to extract or import data between a mainframe database and a HiRDB or ORACLE database or to create files from a mainframe database

To do the following, you must set up a communication environment with XNF or XNF E2.

Extract data from XDM/RD and import it into HiRDB or create a file.

Extract data from a sequential dataset and then import it into HiRDB or create a file.

Extract data from HiRDB or ORACLE and then import it into XDM/RD or create a sequential dataset.

3. Extracting and Importing Data and Creating Files

This chapter explains the procedures for extracting and importing data and for creating files.

Organization of this chapter

3.1 Extracting data (HiRDB)

3.2 Extracting data (ORACLE)

3.3 Importing data

3.4 Creating files

3.1 Extracting data (HiRDB)

Data extraction by HiRDB Dataextractor involves extracting data from a database and then sending that data to a target system. HiRDB Dataextractor enables you to extract only selected data and also to add fields to the extracted data.

The explanation in this section is for data extraction from a HiRDB database and data import into a HiRDB database.

Figure 3-1 shows the data extraction procedure.

Figure 3-1 Data extraction procedure

Organization of this section

3.1.1 Extracting selected data

3.1.2 Adding columns to extracted data

3.1.3 Converting the data type of extracted data

3.1.4 Converting the character codes of extracted data

3.1.1 Extracting selected data

You use the xtrep command to extract data from a HiRDB database. You can extract selected data only by specifying in the xtrep command the name of the table to be extracted and the extraction method.

HiRDB Dataextractor imports extracted data into the target table by establishing correspondence between columns sequentially from left to right. If the formats (number of columns and the order of the columns) do not match between the extraction-system table and the import-system table, you must use the xtrep command to extract data on the basis of the format of the table on the target system.

HiRDB Dataextractor can do the following:

Extract data in units of tables

Select and sort columns to be extracted

Select and sort rows to be extracted

Extract data by a line-by-line interface

Select the default null value

Extract repetition columns

Extract abstract data type columns

Organization of this subsection

(1) Extracting data in units of tables

(2) Selecting and sorting columns to be extracted

(3) Selecting and sorting rows to be extracted

(4) Extracting data by a line-by-line interface

(5) Selecting default null values

(6) Extracting repetition columns

(7) Extracting abstract data type columns

(1) Extracting data in units of tables

You can extract data from a table and import it into another table with the identical format. The following is an example:

Example

Import the ORDER table from the source system to the target system. The ORDER tables on the two systems have the same format, table name, and column names.

Figure 3-2 shows an example of extracting data in units of tables.

Figure 3-2 Extracting data in units of tables

(2) Selecting and sorting columns to be extracted

You can select the columns to be extracted and sort them. To do this, use the following SQL statement provided by HiRDB:

Selection expression in the SELECT statement

Use the xtrep command to specify the name of the file that contains the SELECT statement's selection expression; this file is called the column name specification file. The following is an example:

Example

Select the following columns from the ORDER table, sort them, and then import them:

Product code

Order quantity

Form No.

Figure 3-3 shows an example of selecting and sorting columns to be extracted.

Figure 3-3 Selecting and sorting columns to be extracted

(3) Selecting and sorting rows to be extracted

You can select the rows to be extracted and sort them in ascending or descending order of the data in any column. To do this, use the following SQL statement provided by HiRDB:

WHERE and ORDER BY clauses in the SELECT statement

To extract selected rows, specify the selection condition in the SELECT statement's WHERE clause. To extract sorted rows, specify the sort key and sorting method in the SELECT statements' ORDER BY clause.

Use the xtrep command to specify the name of the file that contains the SELECT statement specifying the WHERE and ORDER BY clauses; this file is called the table expression specification file. The following is an example:

Example

Select the following rows from the ORDER table, sort them, and then import them:

Extract all rows whose order quantity is at least 10.

Sort the rows in ascending order of the customer codes.

Figure 3-4 shows an example of selecting and sorting rows to be extracted.

Figure 3-4 Selecting and sorting rows to be extracted

(4) Extracting data by a line-by-line interface

To extract data from a table with the FIX attribute, you can use a line-by-line interface. The line-by-line interface can improve performance because it eliminates overhead for retrieving individual columns. To extract data using the line-by-line interface, use the following SQL statement provided by HiRDB:

Selection expression (ROW specified) in the SELECT statement

Use the xtrep command to specify the name of the column name specification file that contains the SELECT statement specifying the selection expression. The following is an example:

Example

Import the ORDER table from the source system to the target system using the line-by-line interface. The ORDER tables on the source and target systems have the same format, table name, and column names.

Figure 3-5 shows an example of extracting data by a line-by-line interface.

Figure 3-5 Extracting data by a line-by-line interface

(5) Selecting default null values

When data that is being extracted is the null value, HiRDB Dataextractor sets the data to HiRDB Dataextractor's default null value. During data import, HiRDB Dataextractor compares the extracted data with its default null value and sets the data to the null value if they match. If an applicable column has the NOT NULL constraint, HiRDB Dataextractor imports the default null value as the data.

If the data to be extracted contains HiRDB Dataextractor's default null value, you must change the default null value. To do this, specify a null value information file in the -v option of the xtrep command.

See Table 4-12 for HiRDB Dataextractor's default null value (which is assumed when the -v option is omitted) and the default null values that are specified in the null value information file. The following is an example:

Example

Change the default null values for character string data:

For column CHAR01, which is subject to extraction, use the existing default null value. If data contains ##...#, it will also be set to the null value.

For column CHAR02, which is subject to extraction, change the default null value to a space. If data contains a space, it will also be set to the null value.

For column CHAR03, which is subject to extraction, change the default null value to the literal 'FFFF'. If data contains this literal, it will also be set to the null value.

Figure 3-6 shows an example of changing the default null value.

Figure 3-6 Changing the default null value

If you specify only the default null value that is assumed by HiRDB Dataextractor and the default null values that are specified in the null value information file, the real data in the source table that is the same as the default null value is imported as the null value. To prevent such real data from being imported as the null value, use one of the methods described below.

Changing the default null value

Adding null value checking information to the extracted data

(a) Changing the default null value

For the data types listed below (containing a range of values that cannot be specified as data), you can prevent real data from being imported as the null value by setting as HiRDB Dataextractor's default null value a range of values that cannot be specified as real data:

DECIMAL

DATE

INTERVAL YEAR TO DAY

TIME

INTERVAL HOUR TO SECOND

TIMESTAMP

For other data types, you must set a value that is not used operationally as the default null value because there will be no such value that cannot be specified as data.

(b) Adding the null value checking information to the extracted data

You can prevent real data from being imported as the null value by adding information used to check for the null value to the extracted data without using the default null value.

This data format is the same as for the input data when the database load utility's (pdload) -W option is specified.

(6) Extracting repetition columns

HiRDB Dataextractor can extract and import repetition columns. This section discusses the following topics associated with the use of repetition columns:

Combination of columns between source and target systems when there are repetition columns

Specification of repetition column's data format and null value handling method

Notes on the specification of data format and null value handling method

Data format of repetition columns during file output

(a) Combination of columns between source and target systems when there are repetition columns

Table 3-1 shows whether or not HiRDB Dataextractor supports the combination of columns between source and target systems when there are repetition columns.

Table 3-1 Support of the combination of columns between source and target systems when there are repetition columns

Column on source system | Column on target system | Number of elements | Support
Non-repetition column | Non-repetition column | N/A | P
Repetition column | All elements | N/A | T
Specific elements | N/A | N/A
Repetition column | All elements | Non-repetition column | N/A | T
Repetition column | All elements | Source system = target system | P
Source system < target system | T
Source system > target system | T
Specific elements | N/A | N/A
Specific elements | Non-repetition column | N/A | P
Repetition column | All elements | N/A | T
Specific elements | N/A | N/A

Number of elements: Number of elements in the repetition column.

Support: HiRDB Dataextractor's processing.

P: Processed normally.

T: Terminated.

N/A: Not applicable.

(b) Specification of repetition column's data format and null value handling method

When the repetition columns are output to a file, you can use the following to specify the data format of the repetition columns and the null value handling method:

XTARRAY environment variable

Null value information file (specified in the xtrep command's -v option)

Use the XTARRAY environment variable to specify the data format and null value handling method for each table. To specify this information for each column, use the null value information file that is specified in the -v option of the xtrep command. If you specify both the XTARRAY environment variable and a null value information file, the null value information file takes precedence. If you omit the XTARRAY environment variable, VV and C are assumed.

If 2 is specified in the XTNLDFLT environment variable, and data is imported into a HiRDB table or a binary-format file is created, this environment variable is ignored, and VV and C are assumed.

Data format

Specify the data format of a repetition column that is to be output to a file:

FF

The number of elements is not at the beginning of a column and there is data for all column elements.

FV

The number of elements is at the beginning of a column and there is data for all column elements.

VV

The number of elements is at the beginning of a column and there are as many data items as there are elements.

Null value handling method

Specify how to handle the null value if all elements are the null value when a repetition column is imported into a HiRDB table. You can specify the null value handling method only when data is to be imported into a HiRDB table and the data format is FF.

C

When there is no data for any element, handle the entire column as the null value.

E

When there is no data for any element, handle each element as a null value.

Table 3-2 shows the supported combinations data format and null value handling method for a repetition column.

Table 3-2 Combinations of data format and null value handling method for a repetition column

Facility to be executed | Specified value | Support
Data format | Null value handling method
Import to HiRDB table | FF | None | Y
C
E
FV | None | Y
C | --
E
VV | None | Y
C | --
E
File creation | Binary format | FF | None | Y
C | --
E
FV | None | Y
C | --
E
VV | None | --
C
E
DAT format | FF | None | Y
C | --
E
FV | None | --
C
E
VV | None | Y
C | --
E

Y: Supported.

--: Not supported.

(c) Notes on the specification of data format and null value handling method

You should note the following about specifying the data format and null value handling method:

You cannot specify a data format or null value handling method for a non-repetition column.

If you are creating a file in DAT format, you cannot specify FV for the data format.

If the table subject to processing contains a variable-length character string, FF or FV cannot be specified for the data format.

If you are only creating a file, you cannot specify a null value handling method.

If you specify the FF data format and a null value handling method, the specified null value handling method takes effect when data is imported into the specified HiRDB table. Therefore, the null value for the entire column can no longer be distinguished from the null value for the entire element; as a result, the data status may change between the source and target systems.

Example

If both HiRDB Dataextractor and HiRDB Datareplicator are used at the same time in the same system and the following conditions are satisfied, HiRDB Datareplicator results in an error during import processing:

Data format FF and null value handling method E were specified with HiRDB Dataextractor to import the null value for the entire column on the source system as the null value for the entire element.

A UAP updated (added elements to) the record processed in 1 above and HiRDB Datareplicator was used to incorporate the change.

(d) Data format of repetition columns during file output

Table 3-3 shows the data format of repetition columns (binary format) during data import into a HiRDB table. Table 3-4 shows the data format of repetition columns during creation of a binary-format file. Table 3-5 shows the data format of repetition columns during creation of a DAT-format file.

Table 3-6 describes the data format of repetition columns when 2 is specified in the XTNLDFLT environment variable and data is imported into a HiRDB table or a binary-format file is created.

Table 3-3 Data format of repetition columns during data import into a HiRDB table (binary format)

Extracted data | Specification for repetition column | Contents of output data* | Imported data
Data format | Null value handling method
There are elements | All | FF | N/A | E₁ | ... | EN | All
FV | N/A | N | E₁ | ... | EN
VV | N/A | N | E₁ | ... | EN
Some | FF | N/A | E₁ | ... | En | ... | NVN | Some
FV | N/A | n | E₁ | ... | En | ... | NVN
VV | N/A | n | E₁ | ... | En | --
There is no element | Null value in entire column | FF | Not specified | NV₁ | ... | NVN | Null value in entire column
C | NV₁ | ... | NVN
E | NV₁ | ... | NVN | Null value in each element
FV | N/A | 0 | NV₁ | ... | NVN | Null value in entire column
VV | N/A | 0 | --
Null value in all elements | FF | Not specified | NV₁ | ... | NVN | Null value in entire column
C | NV₁ | ... | NVN
E | NV₁ | ... | NVN | Null value in each element
FV | N/A | N | NV₁ | ... | NVN | Null value in each element
VV | N/A | N | NV₁ | ... | NVN

N/A: Not applicable

Ex: Element x

NVx: Null value x

N: Maximum number of elements

n: Actual number of elements

* Indicates each element sequentially from left to right that is placed in the output data. A - column means that there is no corresponding element.

Table 3-4 Data format of repetition columns during creation of a binary-format file

Extracted data | Specification for repetition column | Contents of output data* | Remarks
Data format | Null value handling method
There are elements | All | FF | N/A | E₁ | ... | EN | --
FV | N/A | N | E₁ | ... | EN
VV | N/A | N | E₁ | ... | EN
Some | FF | N/A | E₁ | ... | En | ... | NVN | --
FV | N/A | N | E₁ | ... | En | ... | NVN | --
VV | N/A | N | E₁ | ... | En | --
There is no element | Null value in entire column | FF | N/A | NV₁ | ... | NVN | --
FV | N/A | 0 | NV₁ | ... | NVN
VV | N/A | 0 | -- | --
Null value in all elements | FF | N/A | NV₁ | ... | NVN | --
FV | N/A | N | NV₁ | ... | NVN
VV | N/A | N | NV₁ | ... | NVN

N/A: Not applicable

Ex: Element x

NVx: Null value x

N: Maximum number of elements

n: Actual number of elements

* Indicates each element sequentially from left to right that is placed in the output data. A - column means that there is no corresponding element.

Table 3-5 Data format of repetition columns during creation of a DAT-format file

Extracted data | Specification for repetition column | Contents of output data* | Remarks
Data format | Null value handling method
There are elements | All | FF | N/A | Element₁, ..., ElementN | Number of commas = N - 1
FV | N/A | N/A | Not specifiable
VV | N/A | N, Element₁, ..., ElementN | Number of commas = N
Some | FF | N/A | Element₁, ..., Elementn, ..., | Number of commas = N - 1
FV | N/A | N/A | Not specifiable
VV | N/A | n, Element₁, ..., Elementn | Number of commas = n
There is no element | Null value in entire column | FF | N/A | , ..., | Number of commas = N - 1
FV | N/A | N/A | Not specifiable
VV | N/A | 0 | Number of commas = 0
Null value in all elements | FF | N/A | , ..., | Number of commas = N - 1
FV | N/A | N/A | Not specifiable
VV | N/A | N, ..., | Number of commas = N

N/A: Not applicable

N: Maximum number of elements

n: Actual number of elements

* Indicates each element sequentially from left to right that is placed in the output data.

Table 3-6 Data format of repetition columns during data import into a HiRDB table, and creation of a binary-format file when 2 is specified in the XTNLDFLT environment variable

Extracted data | Contents of output data¹ | Imported data²
There are elements | All | N | NVF₁ | E₁ | ... | NVFN | EN | There are elements
Some | n | NVF₁ | E₁ | ... | NVFn | En | There are some elements
There are no elements | Null value in entire column | (Offset is set to 0 and no column data is created) | Null value in entire column
Null value in all elements | N | NVF₁ | ... | NVFN | ... | Null value in all elements

N: Maximum number of elements (2-byte area)

n: Actual number of elements (2-byte area)

Ex: Element x; this is not created when null value flag is 1.

NVFx: Null value flag x; 1-byte area

The following table describes the relationship between the contents of the null value flag and element:

Extracted data | Null value flag | Whether or not element information is created
Null value | 1 | Not created. There is only null value flag.
Non-null value | 0 | Created.

¹ Indicates each element contained in the output data from left to right. A blank column means that there is no applicable element.

² Indicates the imported data if data is imported into a HiRDB table.

(7) Extracting abstract data type columns

HiRDB Dataextractor can extract and import abstract data type (ADT) columns. The abstract data type supported by HiRDB Dataextractor Version 5.0 and later is the SGMLTEXT type.

The SGMLTEXT type defines original text data as having the BLOB attribute. HiRDB Dataextractor can extract such original text data.

This section explains how to extract SGMLTEXT-type data.

(a) Specifying environment variables

To extract SGMLTEXT-type data, you must specify the following environment variables:

XTLOBBUFSIZE environment variable
Specify the maximum length of the real data in the SGMLTEXT-type column with the BLOB attribute.
You can use the xtrep command to obtain the maximum length of the real data. You do this by using HiRDB Text Search Plug-in's extracts abstract data type function to specify in the column name specification file the selection expression to be used to obtain the maximum length of the SGMLTEXT-type column that is to be subject to extraction, Then, you execute the xtrep command, and specify the obtained value in the XTLOBBUFSIZE environment variable.

XTERRLEVEL environment variable
Specify the value 1 in this environment variable so that processing will be canceled in the event of an error.

(b) Specifying the xtrep command

To extract SGMLTEXT-type data, you must specify the following information in the xtrep command:

Column name specification file in the -s option
Use the extracts abstract data type function to specify in the column name specification file the SGMLTEXT-type column and other columns to be extracted, and then execute the xtrep command. For an execution example, see (f) Example 6 in (2) Execution examples of 4.4 Examples.

(c) Notes

To extract SGMLTEXT-type data, all the following conditions must be satisfied:

The source and target systems must have the same abstract data type definitions (type name, number of attributes, attribute data type, etc.).

The name of the constructor function must be the same as the name of the abstract data type.

The source and target systems must have the same abstract data type definitions for the HiRDB plug-in (the text type definitions for the SGMLTEXT type).

When processing involves only file creation, a LOB input file is created and stored in the LOB input file storage directory for each LOB data item in the SGMLTEXT-type column with the BLOB attribute.
Note that you can store this LOB data in the input file by specifying the SGMLTEXT data type in the import information file.

3.1.2 Adding columns to extracted data

You can add columns to extracted data and specify an initial value for each such column. When the extraction-system and import-system tables do not have the same number of columns, you can use this feature to add initial values to the extraction data for the columns that exist only in the target table (on the target system).

To add a column to extracted data, use the following SQL statement provided by HiRDB:

Selection expression in the SELECT statement

Use the xtrep command to specify the name of the column name specification file that contains the SELECT statement that specifies the selection expression. The following is an example:

Example

Add the following column to the ORDER table on the source system and import it into the ORDER2 table on the target system. Figure 3-7 shows an example of adding a column.

Order date (initial value: '960715')

Figure 3-7 Adding a column (initial value)

3.1.3 Converting the data type of extracted data

This section discusses the data types that can be converted during the import operation and compared to selected rows to be extracted.

Tables 3-7 and 3-8 list the data types that HiRDB Dataextractor can convert and compare. When it imports data, HiRDB Dataextractor compares a column to be extracted with the column to be imported and executes data type conversion if they constitute any of the combinations listed in Tables 3-7 and 3-8. When it selects a row to be extracted, HiRDB Dataextractor compares the specified data if the conditions in the table expression specification file match the appropriate combination of data types listed in Tables 3-7 and 3-8.

Notes

Overflow error during data type conversion
If an overflow error occurs during data type conversion, HiRDB Dataextractor takes one of the following actions, depending on the specification of pd_overflow_suppress in the HiRDB system common definitions:

If the suppression of overflow errors is specified:
Regards the result of the operation that caused the overflow error as the null value.

If the suppression of overflow errors is not specified:
Outputs an error message and terminates processing.

Character code set
The HiRDB systems on the source and target systems must use the same character code set; do not execute HiRDB Dataextractor if they use different character code sets (if you execute HiRDB Dataextractor, the results may not be correct).

Table 3-7 Data types that HiRDB Dataextractor can convert and compare (1/2)

Data type on source system
Data type on target system

Numeric data
Character string data, mixed character string data ¹⁴
National character data ¹⁴
Date data

Numeric data
INT
Y
--
--
--

SMALLINT

DEC¹⁵

FLOAT

SMALLFLT

Character string data¹⁵
CHAR
--
Y¹¹
Y¹⁴
²

VARCHAR

Mixed character string data¹⁵
MCHAR
--
Y¹¹
Y¹⁴
--

MVARCHAR

National character data¹⁵
NCHAR
--
Y¹²
Y¹¹
--

NVARCHAR

Date data
DATE
--
³
--
Y

Time data
TIME
--
⁸
--
--

Date interval data
YEAR
⁴
--
--
--

Time interval data
HOUR
⁹
--
--
--

Time stamp data
TIMESTAMP
--
--¹⁶
--
--

Large object data15, 20
BLOB
BINARY
--
--
--
--

Abstract data
SGMLTEXT
--
--
--
--

Table 3-8 Data types that HiRDB Dataextractor can convert and compare (2/2)

Data type on source system
Data type on target system

Time data
Date interval data
Time interval data
Time stamp data
Large object data 15, 20
Abstract data

Numeric data
INT
--
¹
⁶
--
--
--

SMALLINT

DEC¹⁵

FLOAT

SMALLFLT

Character string data¹⁵
CHAR
⁷
--
--
--¹⁷
--¹⁹
--

VARCHAR

Mixed character string data¹⁵
MCHAR
--
--
--
--
--¹⁹
--

MVARCHAR

National character data¹⁵
NCHAR
--
--
--
--
--
--

NVARCHAR

Date data
DATE
--
--
--
--
--
--

Time data
TIME
Y
--
--
--
--
--

Date interval data
YEAR
--
Y⁵
--
--
--
--

Time interval data
HOUR
--
--
Y¹⁰
--
--
--

Time stamp data
TIMESTAMP
--
--
--
Y¹⁸
--
--

Large object data15, 20
BLOB
BINARY
--
--
--
--
Y
--

Abstract data
SGMLTEXT
--
--
--
--
--
Y

Y: Can be converted and compared.

--: Cannot be converted or compared.

YEAR: INTERVAL YEAR TO DAY

HOUR: INTERVAL HOUR TO SECOND

¹ Comparison with and conversion to date interval data is supported in the following cases:

Comparison with a literal that expresses the date interval in decimal

Comparison and conversion with DECIMAL(8,0) data

² Comparison with date data is supported in the following cases:

Comparison with a literal that expresses the date in characters

Comparison with CHARACTER(10) data

³ Comparison with date data and conversion to character data is supported in the following cases:

Comparison with a literal that expresses the date in characters

Comparison with CHARACTER(10) data

Conversion of date data to CHARACTER or VARCHAR data with a length of at least 10 bytes

⁴ Comparison with date interval data and conversion to decimal data is supported in the following cases:

Comparison with a literal that expresses a date interval in decimal

Comparison with DECIMAL(8,0) data

Conversion from date interval data to DECIMAL(8,0) data

⁵ Comparison between two date interval data items takes place in the order of year, month, and date.

⁶ Comparison with and conversion to time interval data is supported in the following cases:

Comparison with a literal that expresses a time interval in decimal

Comparison and conversion with data corresponding to DECIMAL(6,0)

⁷ Comparison with time data is supported in the following cases:

Literal that expresses the time in characters

Comparison with CHARACTER(8) data

⁸ Comparison with time data and conversion to character data is supported in the following cases:

Comparison with a literal that expresses the time in characters

Comparison with CHARACTER(8) data

Conversion from time data to CHARACTER or VARCHAR data with a length of at least eight bytes

⁹ Comparison with time interval data and conversion to decimal data is supported in the following cases:

Comparison with a literal that expresses a time interval in decimal

Comparison with DECIMAL(6,0) data

Conversion from time interval data to DECIMAL(6,0) data

¹⁰ Comparison between two time interval data items takes place in the order of hour, minute, and second.

¹¹ If data on the source system is shorter than the data on the target system, HiRDB Dataextractor pads the data with trailing spaces.

¹² You should note the following when you execute with this combination:

The data length on the target system must be equal to or greater than 2 times the number of characters on the source system.

If the data on the source system is shorter than the data on the target system, HiRDB Dataextractor sets one-byte space characters.

HiRDB Dataextractor stores the data from the source system into the target system as is.

If N(VAR)CHAR spaces are intermixed with one-byte spaces, comparison involving spaces may not produce reliable results.

¹³ You should note the following when you execute with this combination:

The data length on the source system must be equal to or less than 2 times the number of characters on the target system.

Do not assign single-byte codes in a column defined as N(VAR)CHAR (if you assign single-byte codes, the data search may not produce reliable results).

If the data on the source system is shorter than the data on the target system, HiRDB Dataextractor sets one-byte space characters.

HiRDB Dataextractor stores the data from the source system into the target system as is.

¹⁴ Data truncation occurs in the following cases:

If a nonzero value is specified in the XTERRLEVEL environment variable, processing depends on the specified value:

Character string, mixed character string, or national character string data:
Data length on the source system > data length on the target system

Decimal data:
Length of integer part on the source system > length of the integer part on the target system
or
Length of decimal part on the source system > length of decimal part on the target system

¹⁵ Data conversion and comparison is not supported if the data on the source system is longer than the data on the target system. However, if the XTLOBBUFSIZE environment variable is specified, HiRDB Dataextractor processes the data according to the specification of the XTERRLEVEL environment variable.

¹⁶ Conversion from time stamp data to character data (CHAR(n), VARCHAR(n)) is supported in the following cases:

The time stamp data does not include decimal places for seconds and the length of the character data is at least 19 bytes.

The time stamp data has 2 decimal places for seconds and the length of the character data is at least 22 bytes.

The time stamp data has 4 decimal places for seconds and the length of the character data is at least 24 bytes.

The time stamp data has 6 decimal places for seconds and the length of the character data is at least 26 bytes.

¹⁷ Conversion from character data (CHAR(n), VARCHAR(n)) to time stamp data is supported in the following cases:

CHARACTER or VARCHAR is the time stamp data.

The TIMESTAMP_FORMAT scalar function is specified in the column name specification file. Decimal places for seconds are truncated if the target is too short and are padded with 0x00 if the target is too long.

¹⁸ If the decimal places for seconds do not match, they are truncated if the target is too short and are padded with 0x00 if the target is too long.

¹⁹ Conversion is supported in the following cases:

Character or mixed character data is converted to BINARY data.

Hexadecimal literals are specified in the column name specification file and imported to BINARY data.

²⁰ Types other than the BLOB type for large object data can be used.

3.1.4 Converting the character codes of extracted data

When you extract or import data between systems that employ different character locales, you can convert the extracted data to the character codes employed by the target system.

This subsection describes the character code sets that can be converted. For details about how to use this function, see 4.2.3 Additional data extraction and import functions.

Organization of this subsection

(1) Data types supported for conversion of character codes

(2) Convertible character code sets

(3) Character code set conversion ranges

(4) Converting from SJIS to EUC

(5) Converting from SJIS to UTF-8

(6) Converting from EUC to SJIS

(7) Converting from EUC to UTF-8

(8) Converting from UTF-8 to SJIS or EUC

(1) Data types supported for conversion of character codes

For extracted data, the following data types are supported for conversion of character codes:

CHAR¹

VARCHAR¹

MCHAR¹

MVARCHAR¹

NCHAR¹

NVARCHAR¹

SGMLTEXT1, 2

¹ You can use the null value information file to exclude desired columns from code conversion. For details about how to specify the null value information file, see 4.2.4 Contents of files specified with the xtrep command.

² If you are only creating a file without importing data into a HiRDB table, the data type is excluded from code conversion because it is treated as having the BLOB attribute. In such a case, you can use one of the following methods to convert the codes of such data:

In the null value information file, specify CODECONV.

For details about the specification method, see 4.2.4 Contents of files specified with the xtrep command.

In the import information file, specify the SGMLTEXT type.

For details about the specification method, see 4.2.4 Contents of files specified with the xtrep command.

If you are using the created file as the input file of pdload, use this method to convert the codes.

(2) Convertible character code sets

The following table shows the combinations of character codes sets that can be converted by HiRDB Dataextractor:

Source character code set | Target character code set
SJIS | EUC | UTF-8
SJIS | -- | Y | Y
EUC | Y | -- | Y
UTF-8 | Y | Y | --

Legend:

Y: Can be converted.

--: Cannot be converted.

(3) Character code set conversion ranges

Figure 3-8 shows the conversion range for the SJIS character code set.

Figure 3-8 SJIS character code set conversion range

Figure 3-9 shows the conversion range for the EUC character code set.

Figure 3-9 EUC character code set conversion range

Table 3-9 shows the conversion range for the UTF-8 character code set.

Table 3-9 UTF-8 character code set

1st byte | 2nd byte | 3rd byte | Conversion rule
0x00-0x7F | -- | -- | Recognize as a 1-byte code, and convert to the corresponding code.
0x80-0xBF | 0x00-0xFF | -- | Convert to 0x20.
-- | --
0x2C-0xDE | 0x80-0xFF | -- | Recognize as a 2-byte code, and convert to the corresponding code.
Other than above | -- | Convert according to the specification of the XTUNDEF environment variable.
-- | -- | Recognize as an incomplete code, and skip without converting it.
0xDF | 0x80-0xBF | -- | Recognize as a 2-byte code, and convert to the corresponding code.
Other than above | -- | Convert according to the specification of the XTUNDEF environment variable.
-- | -- | Recognize as an incomplete code, and skip without converting it.
0xE0 | 0xA0-0xFF | 0x80-0xFF | Recognize as a 3-byte code, and convert to the corresponding code.
Other than above | Convert according to the specification of the XTUNDEF environment variable.
-- | Recognize as an incomplete code, and skip without converting it.
Other than above | 0x80-0xFF | Convert according to the specification of the XTUNDEF environment variable.
Other than above
-- | Recognize as an incomplete code, and skip without converting it.
-- | --
0xE1-0xEE | 0x80-0xFF | 0x80-0xFF | Recognize as a 3-byte code, and convert to the corresponding code.
Other than above | Convert according to the specification of the XTUNDEF environment variable.
-- | Recognize as an incomplete code, and skip without converting it.
Other than above | 0x80-0xFF | Convert according to the specification of the XTUNDEF environment variable.
-- | Recognize as an incomplete code, and skip without converting it.
-- | --
0xEF | 0x80-0xBF | 0x80-0xBF | Recognize as a 3-byte code, and convert to the corresponding code.
Other than above | Convert according to the specification of the XTUNDEF environment variable.
-- | Recognize as an incomplete code, and skip without converting it.
Other than above | 0x80-0xBF | Convert according to the specification of the XTUNDEF environment variable.
Other than above
-- | Recognize as an incomplete code, and skip without converting it.
-- | --
Other than above | -- | -- | Convert according to the specification of the XTUNDEF environment variable.

Legend:

--: The character codes are not converted.

(4) Converting from SJIS to EUC

(a) Single-byte codes ((1) - (4) in Figure 3-8)

Each code is converted to the corresponding EUC code.

Kana characters are converted to single-byte EUC codes.

Space character (0x20) remains unchanged (0x20).

(b) Double-byte codes (SJIS standard Kanji area; (6) and (7) in Figure 3-8)

Each code is converted to the corresponding code in the EUC standard Kanji area.

(c) Double-byte codes (Gaiji area; (8) in Figure 3-8)

Each code is converted according to a mapping table for converting character codes. If a code is not defined in the mapping table, it is regarded as being undefined and is converted to the value specified in the XTUNDEF environment variable. For details about mapping tables for converting character codes, see 4.2.3 Additional data extraction and import functions. For details about the environment variables, see 2.2.3 Specifying environment variables.

Space character (0x8140) is converted to space character (0xa1a1).

(d) Double-byte codes (other than (b) or (c))

All other double-byte codes are regarded as being undefined and are converted to the value specified in the XTUNDEF environment variable. For details about the environment variables, see 2.2.3 Specifying environment variables.

(5) Converting from SJIS to UTF-8

(a) Single-byte codes

Each code is converted to the corresponding UTF-8 code.

Kana characters are converted to triple-byte UTF-8 codes.

Space character (0x20) remains unchanged (0x20).

(b) Double-byte codes (standard character set)

Each code is converted to the corresponding standard character code of UTF-8.

(c) Double-byte codes (Gaiji codes)

Each code is converted according to a mapping table for converting character codes. If a code is not defined in the mapping table, it is regarded as being undefined and is converted to the value specified in the XTUNDEF environment variable. For details about mapping tables for converting character codes, see 4.2.3 Additional data extraction and import functions. For details about the environment variables, see 2.2.3 Specifying environment variables.

Space character (0x8140) is converted to space character (0xE38080).

(d) Double-byte codes (other than (b) or (c))

All other double-byte codes are regarded as being undefined and are converted to the value specified in the XTUNDEF environment variable. For details about the environment variables, see 2.2.3 Specifying environment variables.

(6) Converting from EUC to SJIS

(a) Single-byte codes ((1) - (4) in Figure 3-9)

Each code is converted to the corresponding SJIS code.

Kana characters are converted to single-byte SJIS codes.

Space character (0x20) remains unchanged (0x20).

(b) Double-byte codes (Standard Kanji codes; (6) in Figure 3-9)

Each code is converted to the corresponding code in the SJIS standard Kanji area.

(c) Double-byte codes (Gaiji area; (5) in Figure 3-9)

Each code is converted according to a mapping table for converting character codes. If a code is not defined in the mapping table, it is regarded as being undefined and is converted to the value specified in the XTUNDEF environment variable. For details about mapping tables for converting character codes, see 4.2.3 Additional data extraction and import functions. For details about the environment variables, see 2.2.3 Specifying environment variables.

Space character (0xa1a1) is converted to space character (0x8140).

Code set 3 may result in an error during data import to HiRDB.

(d) Double-byte codes (other than (b) or (c))

All other double-byte codes are regarded as being undefined and are converted to the value specified in the XTUNDEF environment variable. For details about the environment variables, see 2.2.3 Specifying environment variables.

(7) Converting from EUC to UTF-8

(a) Single-byte codes

Each code is converted to the corresponding UTF-8 code.

Space character (0x20) remains unchanged (0x20).

(b) Double-byte codes (standard character set)

Each code is converted to the corresponding standard character code of UTF-8.

Kana characters are converted to triple-byte UTF-8 codes.

(c) Double-byte codes (Gaiji code)

Each code is converted according to a mapping table for converting character codes. If a code is not defined in the mapping table, it is regarded as being undefined and is converted to the value specified in the XTUNDEF environment variable. For details about mapping tables for converting character codes, see 4.2.3 Additional data extraction and import functions. For details about the environment variables, see 2.2.3 Specifying environment variables.

Space character (0x8140) is converted to space character (0xE38080).

(d) Double-byte codes (other than (b) or (c))

All other double-byte codes are regarded as being undefined and are converted to the value specified in the XTUNDEF environment variable. For details about the environment variables, see 2.2.3 Specifying environment variables.

(8) Converting from UTF-8 to SJIS or EUC

(a) Single-byte codes

Each code is converted to the corresponding character code.

Space character (0x20) remains unchanged (0x20).

(b) Double-byte codes (standard character set)

Each code is converted to the corresponding character code.

(c) Double-byte codes (Gaiji codes)

Each code is converted according to a mapping table for converting character codes. If a code is not defined in the mapping table, it is regarded as being undefined and is converted to the value specified in the XTUNDEF environment variable. For details about mapping tables for converting character codes, see 4.2.3 Additional data extraction and import functions. For details about the environment variables, see 2.2.3 Specifying environment variables.

Conversion of space character (0xE38080) differs depending on the corresponding character code type.

SJIS
Space character (0xE38080) is converted to space character (0x8140).

EUC
Space character (0xE38080) is converted to space character (0xa1a1).

(d) Double-byte codes (other than (b) or (c))

All other double-byte codes are regarded as being undefined and are converted to the value specified in the XTUNDEF environment variable. For details about the environment variables, see 2.2.3 Specifying environment variables.

3.2 Extracting data (ORACLE)

Data extraction by HiRDB Dataextractor involves extracting data from a database and then sending that data to a target system. HiRDB Dataextractor enables you to extract only selected data and also to add fields to the extracted data.

The explanation in this section is for data extraction from an ORACLE database and data import into a HiRDB database.

For details about data extraction from an ORACLE database and data import into an XDM/RD database, see the manual Database Extraction Program XDM/XT.

If you are extracting data from an ORACLE database, you must create the ORACLE extraction library in advance in the user environment to be used by HiRDB Dataextractor.

Organization of this section

3.2.1 Extracting selected data

3.2.2 Adding columns to extracted data

3.2.3 Converting the data type of extracted data

3.2.4 Converting the character codes of extracted data

3.2.1 Extracting selected data

You use the xtrepO command to extract data from an ORACLE database. You can extract selected data only by specifying in the xtrepO command the name of the table to be extracted and the extraction method.

HiRDB Dataextractor imports extracted data into the target table by establishing correspondence between columns sequentially from left to right. If the formats (number of columns and the order of the columns) do not match between the extraction-system table and the import-system table, you must use the xtrepO command to extract data on the basis of the format of the table on the target system.

HiRDB Dataextractor can do the following:

Extract data in units of tables

Select and sort columns to be extracted

Select and sort rows to be extracted

Select the default null value

Organization of this subsection

(1) Extracting data in units of tables

(2) Selecting and sorting columns to be extracted

(3) Selecting and sorting rows to be extracted

(4) Selecting default null values

(1) Extracting data in units of tables

For details, see (1) in 3.1.1 Extracting selected data. Note that the command that is used is xtrepO, not xtrep.

(2) Selecting and sorting columns to be extracted

For details, see (2) in 3.1.1 Extracting selected data. Note that the command that is used is xtrepO, not xtrep.

(3) Selecting and sorting rows to be extracted

For details, see (3) in 3.1.1 Extracting selected data. Note that the command that is used is xtrepO, not xtrep.

(4) Selecting default null values

For details, see (5) in 3.1.1 Extracting selected data. Note that the command that is used is xtrepO, not xtrep.

3.2.2 Adding columns to extracted data

For details, see 3.1.2 Adding columns to extracted data. Note that the command that is used is xtrepO, not xtrep.

3.2.3 Converting the data type of extracted data

This section discusses the data types that can be converted during the import operation.

Tables 3-10 and 3-11 list the data types that HiRDB Dataextractor can convert. When it imports data, HiRDB Dataextractor compares a column to be extracted with the column to be imported and executes data type conversion if they constitute any of the combinations listed in Tables 3-10 and 3-11. When it selects a row to be extracted, HiRDB Dataextractor compares the specified data if the conditions in the table expression specification file match the appropriate combination of data types listed in Tables 3-10 and 3-11.

Table 3-10 Data types that HiRDB Dataextractor can convert (1/2)

Data type on source system (ORACLE's interval data type)
Data type on target system (HiRDB)

Numeric data⁸
INT, SMALLINT, DECIMAL, FLOAT,
SMALLFLT
Character string data, Mixed character string data5,7
CHAR, VARCHAR, MCHAR, MVARCHAR
National character data6,7
NCHAR, NVARCHAR
Date data
DATE
Time data
TIME

NUMBER
Y
Y
--
--
--

CHAR
VARCHAR2
Y¹
Y
Y
--
--

NCHAR
NVARCHAR2
--
Y
Y
--
--

DATE⁴
--
Y
--
Y²
Y³

LONG
--
--
--
--
--

LONG RAW
--
--
--
--
--

RAW
--
--
--
--
--

BLOB
CLOB
NCLOB
BFILE
--
--
--
--
--

Table 3-11 Data types that HiRDB Dataextractor can convert (2/2)

Data type on source system (ORACLE's interval data type)
Data type on target system (HiRDB)

Date interval data
YEAR
Time interval data
HOUR
Time stamp data
TIMESTAMP
Large object data⁹
BLOB, BINARY
Abstract data type
SGMLTEXT

NUMBER
--
--
--
--
--

CHAR
VARCHAR2
--
--
--
--
--

NCHAR
NVARCHAR2
--
--
--
--
--

DATE⁴
Y²
Y³
Y¹⁰
--
--

LONG
--
--
--
Y
--

LONG RAW
--
--
--
Y
--

RAW
--
--
--
Y
--

BLOB
CLOB
NCLOB
BFILE
--
--
--
Y
--

Y: Can be converted.

--: Cannot be converted.

¹ To convert data with the character attribute to numeric data, the data must consist of single-byte numeric characters.

² HiRDB Dataextractor only retrieves date information. If date information represents a B.C. year, HiRDB Dataextractor assumes an error and cancels processing.

³ HiRDB Dataextractor only retrieves time information.

⁴ To convert a single column with the DATE attribute to two columns, such as date data and time data, you must extract the column with the DATE attribute twice.

⁵ You should note the following when you execute with this combination:

If the data on the source system is shorter than the data on the target system, HiRDB Dataextractor sets one-byte space characters.

HiRDB Dataextractor stores the data from the source system into the target system as is.

⁶ You should note the following when you execute with this combination:

The data length on the source system must be equal to or less than 2 times the number of characters on the target system.

If the data on the source system is shorter than the data on the target system, HiRDB Dataextractor sets two-byte space characters.

If the data on the source system consists of an odd number of bytes, HiRDB Dataextractor adds a one-byte space character to it so as to make the length to an even number of bytes.

⁷ Data truncation occurs in the following cases:

If a nonzero value is specified in the XTERRLEVEL environment variable, processing depends on the specified value:

Character string, mixed character string, or national character string data:
Data length on the source system > data length on the target system

⁸ Data truncation occurs in the following cases:

Decimal data:
Length of integer part on the source system > length of the integer part on the target system

⁹ Data conversion is not supported if the data on the source system is longer than the data on the target system. However, if the XTLOBBUFSIZE environment variable is specified, HiRDB Dataextractor processes the data according to the specification of the XTERRLEVEL environment variable.

¹⁰ An error results if the date information is in the BC range. If decimal places for the seconds are defined at the target (other than TIMESTAMP(0)), the data is padded with trailing 0x00.

3.2.4 Converting the character codes of extracted data

When you extract or import data between systems that employ different character code sets, you can convert the extracted data to the character codes used by the target system.

For details about the character code sets that can be converted when data extracted from an ORACLE database is imported, see 3.1.4 Converting the character codes of extracted data. For details about how to use this function, see (3) Character code conversion function in 5.1.3 Additional data extraction and import functions.

3.3 Importing data

Data import by HiRDB Dataextractor involves receiving data from a source system and then setting that data into a HiRDB database on the target system.

The explanation in this section is for data extraction from a HiRDB database and data import into a HiRDB database.

Organization of this section

(1) Specifying the data storage method

(2) Specifying the data import method

(3) Converting the data types

(4) Converting character codes

(5) Creating an output file

(6) Notes on data import

(1) Specifying the data storage method

There are two ways to store data in a HiRDB table:

By table (xtrep command with the -j option omitted)

By RDAREA (xtrep command with the -j option specified)

(a) Storing data by table

This method uses the HiRDB table as the unit of storage. HiRDB Dataextractor assumes this method when the -j option is omitted from the xtrep command. If the target HiRDB table is row-partitioned, you should store data by RDAREA instead of by table in order to reduce the time required to perform data storage because HiRDB Dataextractor can store data in multiple RDAREAs at the same time.

(b) Storing data by RDAREA

This method uses the RDAREA as the unit of storage into a HiRDB table. HiRDB Dataextractor assumes this method when the -j option is specified in the xtrep command. If the target HiRDB table is row-partitioned, you can save processing time by using this method because you can start an instance of HiRDB Dataextractor for each RDAREA in order to execute multiple storage processes in parallel.

HiRDB Dataextractor supports data storage by RDAREA for the following type of row-partitioning:

Key range partitioning

Figure 3-10 provides an overview of storage by RDAREAs, and Table 3-12 shows the handling of data storage by RDAREA.

Figure 3-10 Overview of data storage by RDAREA

Table 3-12 Handling of data storage by RDAREA

Row partitioning method
HiRDB's pdload processing
Handling during extraction
Handling during storage

Key range partitioning
Checks that the input data is within the specified RDAREA storage range before actually storing the data. If the data extends outside the storage range and an error data file is specified (-q option in xtrep command), outputs the corresponding row data to the error data file.
Specifies extraction conditions and extracts the data that satisfies the storage conditions for the specified RDAREA.
In the case of a row-partitioned table in the server, you must use HiRDB's database reorganization utility to create a non-partitioning key index after data storage; see Note below.
You can use the error data file as an input file to pdload. If data that extends outside the storage range is output to the error data file, check the data and use pdload to store it in the table, if necessary.

Note

Creating a non-partitioning key index for a row-partitioned table in the server
In the case of a row-partitioned table in the server, HiRDB Dataextractor assumes the index information output mode for a non-partitioning key index even if you specify c in the -i option of the xtrep command to store data by RDAREA. In such a case, you must use HiRDB's database reorganization utility (pdrorg) to create the non-partitioning index in the batch mode (by specifying ikmk in the-k option of the pdrorg command). For details about the database reorganization utility, see the HiRDB Command Reference manual. In the case of a row-partitioned table between servers, an index is created according to the -i option specification in the xtrep command.

(2) Specifying the data import method

HiRDB Dataextractor uses HiRDB's database load utility (pdload) to import data. You can specify the following import methods using the options of the xtrep command:

Extracted data storage method (-d option)
You can specify a method for storing extracted data into a table. Two methods are available:

Deleting all existing data from the table and then storing the extracted data into the table

Adding the extracting data to the table, retaining the existing data

Index creation method (-i option)
You can specify an index creation method. Four methods are available:

Batch index creation mode
This method creates indexes in batch mode after creating the table.

Index information output mode
This method outputs only the index information to an index information file.

Index update mode
This method updates indexes each time a row of data is stored.

Index information output suppression mode
This method does not update an index.

Parameter specification for pdload command (-l option)
You can specify desired parameters of the pdload command. For details about the use of this function, see 4.2.3 Additional data extraction and import functions or 5.1.3 Additional data extraction and import functions.

Log acquisition method (-l option)
You can select a log acquisition method. By selecting an appropriate log to be acquired according to the operation, you can reduce the log output processing time.

Number of batch output pages (-n option)
You can specify the number of pages to be output to a table in batch mode. By specifying this information, you can improve the importing efficiency HiRDB Dataextractor outputs the specified number of pages in batch mode.

Zero-length data storage (-z option)
Specify this option to store characters with a length of zero. If you specify this option, HiRDB Dataextractor lets you store characters with a length of zero.

(3) Converting the data types

If the data type of a table column on the source system does not match the data type on the target system, HiRDB Dataextractor converts it to the data type for HiRDB columns, if possible. For the convertible data types, see 3.1.3 Converting the data type of extracted data or 3.1.2 Adding columns to extracted data.

(4) Converting character codes

When there is a data linkage between ORACLE and HiRDB systems or between HiRDB systems, character codes can be converted as specified in the environment variable in order to import data. For details about the character codes sets that can be converted, see 3.1.4 Converting the character codes of extracted data. For details about how to use this function, see 4.2.3 Additional data extraction and import functions or 5.1.3 Additional data extraction and import functions.

(5) Creating an output file

The xtrep command lets you output extracted data to a file before starting up pdload. This file is called an output file. The output file is in the binary format. For details about the binary format, see Table 4-16.

To output data to an output file, specify the -o or -O option according to the output file processing method to be used after data is stored in a table. There are two ways of processing the output file:

Saving the output file after storing data to a table (-o option)
To save the output file after completion of import processing, specify the -o option. The created output file will be retained after import processing. You can use this output file as a backup. To re-create a HiRDB table on the basis of this output file in the event of an error, use HiRDB's database load utility.

Deleting the output file after storing data to a table (-O option)
If you want to delete the output file after completion of import processing, specify the -O option.

If extracted columns include a BLOB column, HiRDB Dataextractor creates LOB input files as well as the output file. A LOB input file is created for each LOB data item. You can use the -b option to specify a directory for storing the LOB input files. The -o or -O option determines the LOB input file processing method after import processing. To store BLOB-column data in the same output file as for non-BLOB data without creating a LOB input file, specify the XTLOBKIND environment variable.

If an output file or LOB input file to be created already exists, the -y option determines whether or not to overwrite the existing file. When the -y option is specified, HiRDB Dataextractor deletes the existing file and then outputs data to a new file. When the -y option is omitted, HiRDB Dataextractor outputs a message and terminates the processing.

The output file and LOB input files are created on the host at the following HiRDB server on the target system:

HiRDB/Single Server
Server at the single server

HiRDB/Parallel Server

-f option specified
Front-end server (FES) or back-end server (BES) specified with the -f option

-f option omitted
In the case of data storage in units of tables, the first FES server specified in the pdstart command in the HiRDB system common definitions (pdsys)
In the case of data storage in units of RDAREAs, the back-end server (BES) that contains the RDAREA subject to data storage

(6) Notes on data import

If data is imported into a HiRDB table under the following conditions and an error occurs during import processing, the original status is restored:

No file is created (-o or -O option omitted).

Extracted data is added to the table, retaining the existing data.

To add data, execute data import as follows:

Specify the option in such a manner that files are created to import data to the table.

If you do not want to create a file, make a backup copy beforehand to protect against possible errors.

If pdload returns an error during data import, files that were created during pdload execution may remain. If the files are unnecessary, delete them. For details about the files that are created, see the manual HiRDB Command Reference.

To start HiRDB's database load utility (pdload) with HiRDB Dataextractor, specify pdload's -x option.
If this option is not needed, use the loader parameter specification function. For details about using this function, see (2) Loader parameter specification function in 4.2.3 Additional data extraction and import functions or (2) Loader parameter specification function in 5.1.3 Additional data extraction and import functions.

If a cluster key has been defined for the target table and data is to be imported in the order of the cluster key values, extract the data with the ORDER BY clause of the SELECT statement specified in the column name specification file for the column that corresponds to the source table's cluster key. If you use the code conversion function, the data may not be sorted in ascending (or descending) order because code conversion occurs after data extraction. In this case, use the database reorganization utility to reorganize the data after importing it.

3.4 Creating files

File creation by HiRDB Dataextractor involves receiving data from a source system and then storing the data in a file at the target host.

HiRDB Dataextractor enables you to extract data from a HiRDB database and create an input file for a database system. Combined with XDM/XT, HiRDB Dataextractor can create an input file for a database system using the data sent from a mainframe database. Using a file created with the file creation facility, you can import data into a non-HiRDB database system.

This section explains how to use HiRDB Dataextractor for data source and file creation at the target host.

Organization of this section

(1) Format of file to be created

(2) Data types of the created file

(3) Character codes of the file to be created

(4) Specifying a name for the created file

(5) Executing a shell script

(1) Format of file to be created

To create a file, use the xtrep or xtrepO command's -R option. The -R option enables you to select one of the following two file formats:

Binary format
Extracted data is stored in the file in binary format. For details about the binary format, see Table 4-16.

DAT format
Extracted data, including numeric data, is converted to characters and then stored in the file. For details about the DAT format, see Table 4-15.
The DAT format is commonly called the CSV format. In the case of the DAT format, you can specify a character to be used as the delimiter between data items (separator character). To use the created file as an input file for the target database system on the target system, you must specify the separator character so that it complies with the conventions of the target database system.

(2) Data types of the created file

The data types of the created file depend on the extracted database.

HiRDB
The same data type as for the extracted HiRDB data is assumed. For the SGMLTEXT type, if the SGMLTEXT type is not specified in the import information file, the BLOB type is assumed. You can also change other data types by specifying the -L option.

ORACLE
The extracted data is converted to HiRDB data types because HiRDB Dataextractor assumes that the data is to be imported into HiRDB. The default data type depends on the ORACLE data type, but you can change it with the -L option.

(3) Character codes of the file to be created

When there is a data linkage between ORACLE and HiRDB systems or between HiRDB systems, the character codes can be converted as specified in the environment variable in order to create files. For details about the supported character code sets, see 3.1.4 Converting the character codes of extracted data. For details about how to use this function, see 4.2.3 Additional data extraction and import functions or 5.1.3 Additional data extraction and import functions.

(4) Specifying a name for the created file

You use the -o option to specify a name for the created file, which is referred to as the output file. If the extracted columns contain a BLOB column, HiRDB Dataextractor creates LOB input files as well as the output file. A LOB input file is created for each LOB data item. You can use the -b option to specify a directory for storing the LOB input files. To store BLOB-column data in the same output file as for non-BLOB data without creating LOB input files, specify the XTLOBKIND environment variable.

If an output file or LOB input file to be created already exists, the -y option determines whether or not the existing file is to be overwritten. When the -y option is specified, HiRDB Dataextractor deletes the existing file and then outputs data to the file. When the -y option is omitted, HiRDB Dataextractor outputs a message and terminates processing.

The output file and LOB input files are created at the host at the following HiRDB server on the target system:

-h option specified: Host specified with the -h option

-h option omitted: Host specified in the XTHOST environment variable

(5) Executing a shell script

To execute user-defined processing after file creation, use the -x option to specify the filename of the shell script you want to execute. When the filename of a shell script is specified, HiRDB Dataextractor passes control to the user-created shell script after file creation and then waits for completion of the shell script. When the shell script is completed, HiRDB Dataextractor regains control and terminates the processing.

4. Extracting Data from HiRDB and Importing It into HiRDB

This chapter explains the procedures for extracting data from a HiRDB database and importing it into a HiRDB table or specifying information for file creation.

Organization of this chapter

4.1 Extraction and import conventions

4.2 Command

4.3 Formats of output listings

4.4 Examples

4.1 Extraction and import conventions

This section describes the conventions that apply to extracting data from a HiRDB database and to importing data.

Organization of this section

4.1.1 Conventions for extraction

4.1.2 Conventions for import

4.1.1 Conventions for extraction

This section describes HiRDB Dataextractor's data extraction conventions.

Organization of this subsection

(1) Lock

(1) Lock

HiRDB Dataextractor enables you to lock a table during data extraction. The xtrep command's -g option is used to specify whether or not locking is to be used. By locking the table, you can reduce lock processing time. Table 4-1 shows the relationship between specification of the -g option and the lock mode. For details about the lock modes, see the HiRDB UAP Development Guide.

Table 4-1 Relationship between -g option specification and lock mode

-g option specification | Resources
RDAREA | Table | Row | Key value
For table | For index
Specified (do not lock by issuing LOCK statement) | SR | SR | SR | PR | PR
Omitted (lock by issuing LOCK statement) | SR | N | PR | N | N

SR: Shared retrieval mode

PR: Protected retrieval mode

N: Do not lock

4.1.2 Conventions for import

This section describes HiRDB Dataextractor's data import conventions.

You can import data into the same HiRDB system from which data was extracted or into a different HiRDB system. However, you cannot import data into the same table from which it was extracted; if an attempt is made to do so, the results may not be correct.

4.2 Command

You use the command provided by HiRDB Dataextractor to extract data from a HiRDB database and import it into another HiRDB database or to save it as a file.

Organization of this section

4.2.1 Command format

4.2.2 xtrep command

4.2.3 Additional data extraction and import functions

4.2.4 Contents of files specified with the xtrep command

4.2.1 Command format

This section describes the command format, which is shown below:

Format

command-name options command-argument

Organization of this subsection

(1) command-name

(2) options

(3) command-argument

(1) command-name

The command name is the filename of the command that is to be executed.

To execute a command, you must specify appropriate environment variables in your environment settings. For details about how to specify the environment variables that are required for execution of the xtrep command, see 2.2.3 Specifying environment variables.

(2) options

An option specifies one of the following types of information:

A qualification of the command's action

A qualification of the object of the action

The following explains how to specify options. In the examples, the dollar sign ($) indicates a shell prompt and cmd indicates the command name.

An option is a character string beginning with a hyphen (-). It can be followed by flag arguments (or by no flag arguments). The following is the format of an option:

-option-flag

or

option-flag- flag-arguments

option-flag: One alphanumeric character (which is case sensitive)
flag-arguments: Arguments of the option flag (when you specify multiple flag arguments, you separate them with the comma (,))

If an option flag has a required flag argument, you cannot omit that flag argument.

If a flag argument contains a space, you must enclose the entire flag argument in double quotation marks (") in order to enter the command from the shell.

Example

Option f with arguments 1 and 2 is specified as follows:

$ cmd -f "1 2"

You cannot specify the same option flag more than once.

Specify all options before any command arguments.

(3) command-argument

The command argument specifies the direct object of the command's action.

4.2.2 xtrep command

Organization of this subsection

(1) Function

(2) Executor

(3) Executing server machine

(4) Format

(5) Options

(6) Combination of xtrep command options

(1) Function

The xtrep command extracts data from a specified table and imports it into a target table on the target system. It can also create a file after data extraction, depending on an operand specification.

(2) Executor

There is no specific limitation to what an executor can do, except that the user specified in the PDUSER environment variable must have certain privileges. For details, see (2) in 2.2.3 Specifying environment variables.

Additionally, there are some restrictions on the user who can start HiRDB Dataextractor on the target system. For details, see (3) in 2.2.4 Files required in order to use HiRDB Dataextractor or 6.2.2 Starting and terminating HiRDB Dataextractor when using OSI.

(3) Executing server machine

Execute the xtrep command at the HiRDB server machine that is to be subject to data extraction. This server machine depends on the HiRDB system to be connected (i.e., a HiRDB/Single Server or a HiRDB/Parallel Server). The following shows the server machine at which the xtrep command is to be executed:

HiRDB/Single Server
Server machine at which the single server is located

HiRDB/Parallel Server
Server machine at which one of the following servers is located:

System manager

Front-end server

Back-end server

Dictionary server

(4) Format

xtrep [-r [authorization-identifier.]table-identifier]
     [-R [{bin|dat}][,separator-character]]
     [-o [{output-filename|output-directory-name}
          [,{output-filename|output-directory-name}]...]]
     [-O [{output-filename|output-directory-name}
          [,{output-filename|output-directory-name}]...]]
     [-y]
     [-j RDAREA-name]
     [-h target-host-name]
     [-H single-server's-host-name-or-system-manager's-host-name
       [,front-end-server's-host-name-or-back-end-server's-host-name]]
     [-p port-number]
     [-f front-end-server-name-or-back-end-server-name]
     [-d]
     [-i index-creation-mode]
     [-I [pdload-control-information-environment-variable-name]
        [,pdload-command-line-information-environment-variable-name]
        [,pdload-control-information-file's-source-statement-
          information-environment-variable-name]]
     [-l log-acquisition-mode]
     [-L import-information-file-name]
     [-n batch-output-pages-count]
     [-z]
     [-e error-log-filename]
     [-m progress-message-output-interval]
     [-g [lock-information-filename]]
     [-s column-name-specification-filename]
     [-w table-expression-specification-filename]
     [-v null-value-information-filename]
     [-b LOB-input-file-storage-directory-name]
     [-q error-data-filename[,output-lines-count]]
     [-x shell-script-filename]
     [authorization-identifier.]table-identifier

(5) Options

-r [authorization-identifier.]table-identifier

Specify the name of the table that is to be subject to data import. The -r and -R options are mutually exclusive. If both options are omitted or if the authorization identifier is omitted, HiRDB Dataextractor assumes as follows:

-r option omitted

authorization-identifier:

Authorization identifier specified for the table that is to be subject to extraction:

HiRDB Dataextractor assumes the authorization identifier specified for the table that is to be subject to extraction.

No authorization identifier specified for the table to be subject to extraction:

HiRDB Dataextractor assumes the value set in the PDUSER environment variable that is used by HiRDB Dataextractor on the data target system.

table-identifier:

HiRDB Dataextractor assumes the table identifier of the table that is to be subject to extraction.

authorization-identifier only omitted
HiRDB Dataextractor assumes the value set in the PDUSER environment variable that is used by the HiRDB Dataextractor on the data target system.

Notes

The specified authorization identifier and table identifier are assumed to be in all uppercase letters. To have them handled as being case sensitive, separately enclose each of them (authorization identifier and table identifier) in double quotation marks ("), and then enclose them each separately or both together in single quotation marks (').

If the table identifier contains a space, enclose the entire table identifier in double quotation marks (") and then enclose it in single quotation marks (').

Examples

The following specifications are both regarded as USER01.TABLE01:

user01.table01

"user01"."table01"

The following specifications are both regarded as user01.table01:

'"user01"."table01"'

'"user01"'.'"table01"'

-R [{bin|dat}][,separator-character]

To only create a file after data extraction, use this option to specify the format of the file that is to be created. When this option is specified, HiRDB Dataextractor does not store the extracted data in a table on the target system. To store the data into a target table, omit this option. The -R and -r options are mutually exclusive.

Use the -o option to specify the name of the file that is to be created. For details about the file format, see (4) in 4.2.4 Contents of files specified with the xtrep command.

To execute a user-created shell script after file creation, use the -x option to specify the filename of the shell script.

bin

Create the file in binary format.

HiRDB Dataextractor stores the extracted data in the specified file exactly in the same format as in the HiRDB database.

dat

Create the file in DAT format.

HiRDB Dataextractor converts the extracted data, including numeric data, to characters and then stores them in the specified file. This is referred to commonly as the CSV format.

separator-character ~ <character string> ((1 character)) <<comma (,)>>

If you have specified dat, specify the character you want to use as the separator between data items. If you have specified bin, you cannot specify a separator character.

If you specify dat but omit specification of a separator character, the comma (,) is assumed. To specify a space or a character that has special meaning to the shell (such as a vertical bar (|)), enclose the character in double quotation marks (").

To use the created file as an input file to the target database system on the target system, you must specify the separator character in accordance with the conventions stipulated by the target database system.

Note

When you specify a separator character, do not place spaces before or after the preceding comma (,).

Examples

Correct

-R dat,","

Incorrect

-R dat, ","

There is a space before and after the comma.

-R,","

When bin is specified (or assumed as the default), a separator character cannot be specified.

-o [{output-filename|output-directory-name} [,{output-filename|output-directory-name}]...]

~ <pathname> ((1 length of one name in characters 255) x number of files 511 characters in all))

output-filename: Enter any character other than the forward slash (/) at the end of the specified value.

output-directory-name: Enter the forward slash (/) at the end of the specified value.

If a directory name is specified, HiRDB Dataextractor creates a file by assigning a unique filename.

This option specifies that the extracted data is to be output to a specified output file. It uses a filename or directory name as the output destination. Whether or not the data is to be imported into a table after file creation depends on the -R option.

-R option specified

If the -R option is specified, HiRDB Dataextractor creates the specified output file(s) and does not import the data into a target table. You use the -R option to specify the format of the output file. The output file is created at the following host on the file creation system:

-h option specified: Host specified with the -h option

-h option omitted: Host specified in the XTHOST environment variable

Note that if you create a binary-format file for storing SGMLTEXT-type columns, the data cannot be imported into a HiRDB table.

-R option omitted

If the -R option is omitted, HiRDB Dataextractor imports the data into the target table after it creates the output file. The output file is created in binary format at the host located at the following server of the importing HiRDB:

HiRDB/Single Server: Single server

HiRDB/Parallel Server:
-f option specified: FES or BES specified in the -f option
-f option omitted: FES or BES that is assumed as the default

If you specify the -o option, HiRDB Dataextractor retains the created output file and the file created by HiRDB's database load utility after the import processing; you can use this output file as a backup. To re-create a HiRDB table on the basis of a created output file in the event of an error, use HiRDB's database load utility.

To delete the output file after the import processing, specify the -O option. The -o and -O options are mutually exclusive.

If you specify the -o option, use the -y option to specify the method for handling an existing output file.

If you omit the -o option, HiRDB Dataextractor creates the file with a unique name under the /opt/HIRDBXT/spool directory; for details, see Table 2-3 Directories and files created by HiRDB Dataextractor.

Notes

The total length of the XTTMPDIR environment variable and output filenames must not exceed 255 characters.

If the specified value contains a back slash (\), enclose the specified value in double quotation marks (").

You can specify multiple filenames and directory names in the -o option only if the HiRDB Dataextractor on the import or file creation system supports this feature. If this feature is not supported, HiRDB Dataextractor outputs the JXU7001E message and terminates with an error on the import or file creation system. If the HiRDB Dataextractor on the source system does not support this feature, it will regard the specified filenames or directory names as a single filename.

Example

xtrep -o /hd001/,/hd002/ TBL_NAME

This example creates files with unique names under /hd001/ and /hd002/ and imports data into the target table.

-O [{output-filename|output-directory-name} [,{output-filename|output-directory-name}]...]

~ <pathname> ((1 length of one name in characters 255) x number of files 511 characters in all))

output-filename: Enter any character other than the forward slash (/) at the end of the specified value.

output-directory-name: Enter the forward slash (/) at the end of the specified value.

If a directory name is specified, HiRDB Dataextractor creates a file by assigning a unique filename.

This option specifies that the extracted data is to be output to a specified output file. It uses a filename or directory name as the output destination. HiRDB Dataextractor imports the data into the target table after creating an output file and automatically deletes the output file upon completion of the import processing.

The output file is created in binary format at the host located at the following server of the importing HiRDB:

HiRDB/Single Server: Single server

HiRDB/Parallel Server:
-f option specified: FES or BES specified in the -f option
-f option omitted: FES or BES that is assumed as the default

To retain the output file upon completion of import processing, specify the -o option; to delete it, specify the -O option. The -o and -O options are mutually exclusive. When the -R option is specified, the -O option cannot be specified.

If you specify the -O option, use the -y option to specify the method for handling an existing output file. When the -O option is specified, the filename of the created output file is the same as when the -o option is specified.

Notes

The total length of the XTTMPDIR environment variable and output filenames must be no greater than 255 characters.

If the specified value contains a back slash (\), enclose the specified value in double quotation marks (").

You can specify multiple filenames and directory names in the -O option only if the HiRDB Dataextractor on the import or file creation system supports this feature. If the feature is not supported, HiRDB Dataextractor outputs the JXU7001E message and terminates with an error on the import or file creation system. If the HiRDB Dataextractor on the source system does not support this feature, it will regard the specified filenames or directory names as a single filename.

-y

Use this option to specify whether or not an existing file is to be overwritten when a file to be created already exists during file creation. If you specify the -y option, HiRDB Dataextractor deletes the existing file and then outputs the data to the file. If you omit the -y option, HiRDB Dataextractor outputs a message and terminates the processing. You can specify this option only when the -o, -O, or -b option is specified.

The -y option is applicable to the following files:

Output file (created when the -o or -O option is specified)

LOB input file storage directory and LOB input files (created when the table subject to data extraction contains data for BLOB columns)

Note that HiRDB Dataextractor may not be able to overwrite the file, depending on the file mode.

-j RDAREA-name

~ <identifier> ((1-30))

To store the data into a row-partitioned table by RDAREA, specify the name of the RDAREA. If you have specified the -R option, you cannot specify the -j option. If you omit this option, HiRDB Dataextractor will store the data by table.

Notes

An RDAREA name is assumed to be all uppercase letters. To have it handled as being case sensitive or to specify an RDAREA name containing a space, enclose the RDAREA name in double quotation marks (") and then enclose it in single quotation marks (').

This option is applicable only if the HiRDB Dataextractor on the import or file creation system supports this feature. If the feature is not supported, HiRDB Dataextractor issues the JXU7001E message and terminates with an error on the import or file creation system.

-h target-host-name

Specify the name of the host to which the extracted data is to be sent. You can specify the FQDN instead of the host name.

If you are importing extracted data into a table, specify the host name at the following server:

HiRDB/Single Server: Single server (SDS)

HiRDB/Parallel Server: System manager (MGR)

In the case of file creation, specify the name of the host to be used to create the file.

When the -h option is omitted, HiRDB Dataextractor assumes the value set in the XTHOST environment variable. Specify this host name in /etc/hosts on the data source system. For details about the specification, see 2.2.4 Files required in order to use HiRDB Dataextractor.

Notes

If the host on the source system uses a different LAN than the host on the target system, executing the xtrep command with this option specified will result in a connection establishment error. In such a case, re-execute the command with the -H option specified. The -h and -H options are mutually exclusive.

The host at the system manager and the host at the target server to which data is to be sent (front-end or back-end server) must be accessible from the host on the source system.

If the target HiRDB uses the system switchover facility, specify the name of the host that inherits the IP address.

-H single-server's-host-name-or-system-manager's-host-name [,front-end-server's-host-name-or-back-end-server's-host-name]

Specify the name of the host to which the extracted data is to be imported. You can specify the FQDN instead of the host name.

You use this option when the host on the source system uses a different LAN than the host on the target system.

Specify the name(s) of the host(s) located at the following server(s) on the data target system:

HiRDB/Single Server
Single server (SDS)

HiRDB/Parallel Server
System manager (MGR) and the target server to which the data is to be sent (front-end server (FES) or back-end server (BES))
If you omit the host name of the FES or BES, HiRDB Dataextractor assumes that the MGR's host contains the applicable FES or BES.

When the -H option is omitted, HiRDB Dataextractor assumes the value set in the XTXHOST environment variable. Specify the host name in /etc/hosts on the data source system. For details about the specification, see 2.2.4 Files required in order to use HiRDB Dataextractor.

Notes

The FES or BES host specified with this option must contain the following FES or BES:
-f option specified: FES or BES specified with the -f option
-f option omitted: FES or BES assumed as the default when the -f option is omitted

The -h and -H options are mutually exclusive.

If you specify the -R option, you cannot specify the -H option.

The host at the MGR and the host at the target server to which data is sent must be accessible from the host on the source system.

If the target HiRDB uses the system switchover facility, specify the name of the host that inherits the IP address.

-p port-number

~ <unsigned integer> ((1025-65535))

Specify the port number of the HiRDB Dataextractor that is located at the following host specified with the -h or -H option:

HiRDB/Single Server: Host at the single server

HiRDB/Parallel Server: Host at the system manager and at the target server to which data is to be sent

File creation: Host used to create the file

If the -p option is omitted, HiRDB Dataextractor assumes the value set in the XTPORTNO environment variable. Specify the port number that has been assigned to the HiRDB Dataextractor in /etc/services/ on the import or file creation system. For details about the specification, see 2.2.4 Files required in order to use HiRDB Dataextractor.

Note

If the system manager and the target server to which data is to be sent are located at different hosts, you must assign the same port number to the HiRDB Dataextractors running on these hosts.

-f front-end-server-name-or-back-end-server-name

For a HiRDB/Single Server, specify the name of the front-end server (FES) or back-end server (BES) at the data transmission target. If you omit this option, HiRDB Dataextractor assumes one of the following server names, depending on the data storage method:

Storage by table
HiRDB Dataextractor assumes the name of the first FES specified in the pdstart command in the HiRDB system common definitions (pdsys). For details about the HiRDB system common definitions, see the HiRDB System Definition manual.

Storage by RDAREA
HiRDB Dataextractor assumes the name of the BES that contains the RDAREA that stores the data.

-d

Specify the data storage method for importing the extracted data into a table.

When you specify this option, HiRDB Dataextractor deletes all existing data from the table and then stores the extracted data. If you omit this option and the table already contains data, HiRDB Dataextractor adds the extracted data to the table without deleting the existing data.

The value of this option is that of the -d option specified for HiRDB's database load utility that is started by HiRDB Dataextractor. If this option is omitted and an error occurs during data import processing, HiRDB Dataextractor may not be able to restore the original data unless a or p is specified in the -l option.

-i index-creation-mode

Specify the index creation mode to be used when the extracted data is imported into a table. When this option is omitted, c is assumed. The value of this option is that of the -i option specified for HiRDB's database load utility (pdload) that is started by HiRDB Dataextractor:

c

Use the batch index creation mode. The utility creates indexes in the batch mode after table creation processing.

n

Use the index information output mode. The utility only outputs index information to index information files. When you specify this mode, you must use HiRDB's database reorganization utility to re-create the indexes.

s

Use the index update mode. The utility updates indexes each time a row of data is stored.

x

Use the index information output suppression mode. The utility does not update indexes or output index information to index information files.

If you specify c in the -i option and an error occurs during batch index creation, or if you specify x in the -i option, the table's row data is correct, but the indexes are invalid (not created). In such a case, you need to re-create each index using one of the following methods:

Load zero data items with HiRDB's database load utility
Execute the command in the addition mode with c specified in the -i option.

Re-create the index with HiRDB's database reorganization utility
Execute the command with ikrc specified in the -k option.

-I [pdload-control-information-environment-variable-name]

[,pdload-command-line-information-environment-variable-name]

[,pdload-control-information-file's-source-statement-information-environment-variable-name]

((6-10 characters))

You can specify desired pdload parameters by specifying the names of one or more of the environment variables listed below. You can specify these environment variable names in any order, delimited by the comma (,); you may not specify the same environment variable name more than once.

pdload control information environment variable (XTPDCFxxxx)

pdload command line information environment variable (XTLPRMxxxx)

pdload control information file's source statement information environment variable (XTPDSRxxxx)

For details about each environment variable, see (2) Specification of environment variables in 2.2.3 Specifying environment variables.

Notes

If you omit both this option and the XTPDCFPATH environment variable, pdload creates the index information file and LOB middle file under /tmp. If the target table contains an index or BLOB columns, temporary files are output to /tmp proportionally to the amount of data. If /tmp does not have sufficient space, the entire system may be affected adversely.

You can use this option as a countermeasure in the event of a pdload error due to the following causes:
The target table contains no indexes, but a control information file containing the idxwork or index statement was specified.
The target table contains no BLOB columns, but a control information file containing the lobmid statement was specified.
Create a control information file appropriate to the table definition for each table on the target system and set it in an XTPDCFxxxx environment variable. When you execute HiRDB Dataextractor, use this option to specify the control information file corresponding to the target table.

You can use this option only if the HiRDB Dataextractor on the target or file creation system supports this function. If the function is not supported, HiRDB Dataextractor displays the JXU7001E message at the target or file creation system, resulting in an error.

-l log-acquisition-mode

Specify the log acquisition mode to be used during import of extracted data into a table. When this option is omitted, HiRDB Dataextractor assumes p. The value of this option is that of the -l option specified for HiRDB's database load utility that is started by HiRDB Dataextractor.

a

Use the log acquisition mode. The utility acquires log information required for rollback and rollforward.

p

Use the pre-update log acquisition mode. The utility acquires log information required for rollback, but not for rollforward.

n

Use the no-log mode. The utility does not acquire log information.

For details about how to handle the pre-update log acquisition mode and the no-log mode, see the HiRDB System Operation Guide.

-L import-information-file-name

~ <path name> ((1-255 characters))

Specify the absolute path name of the import information file. This option is required in the following cases:

When the type of extracted data is converted

When the length of extracted data is changed

When pdload is used to load a file created by extracting the SGMLTEXT type

For details about specifying the import information file, see 4.2.4 Contents of files specified with the xtrep command.

-n batch-output-pages-count

~ <unsigned integer> ((8-4096)) <<10>>

To import extracted data into a table, specify the number of pages to be output to the table in the batch mode. The value of this option is that of the -n option specified for HiRDB's database load utility that is started by HiRDB Dataextractor.

-z

Specify this option to store data with a length of zero in variable-length character strings, variable-length national character strings, and variable-length mixed character strings during import of extracted data into a table. If this option is omitted and the extracted data contains a data item with a length of zero, HiRDB's database load utility (pdload) results in an invalid input data error. The value of this option is that of the -z option specified for HiRDB's database load utility that is started by HiRDB Dataextractor.

-e error-log-filename

Specify the absolute pathname of the error log file to which log messages are to be output. If the specified file is not found, HiRDB Dataextractor creates one. There is no need to create this file beforehand.

When you omit this option, HiRDB Dataextractor creates a file with a unique name in the /opt/HIRDBXT/spool. For details, see Table 2-3.

-m progress-message-output-interval

~ <unsigned integer> ((1-1000)) <<10>>

Specify the interval at which messages indicating the data extraction status are to be output; this interval is specified in units of 1000 lines. These messages are output to the error log file and the standard output.

-g

[lock-information-file-name]

~ <pathname> ((1-255 characters))

Specify the lock mode. When this option is specified, any entry of the LOCK statement is ignored. When you omit this option, you must use the LOCK statement to lock resources. For the relationship between the -g option and the lock mode, see 4.1.1 Conventions for extraction.

The relationship between this option and the lock information file is as follows:

When this option is omitted
HiRDB Dataextractor uses the LOCK statement (always LOCK TABLE table-name IN SHARE MODE) for lock control.

When this option is specified
HiRDB Dataextractor does not issue the LOCK statement.

When this option is specified and the lock information file is specified
HiRDB Dataextractor uses the LOCK statement (specified in the lock information file) for lock control.
For details about how to specify the lock information file, see 4.2.4 Contents of files specified with the xtrep command.

-s column-name-specification-filename

~ <pathname> ((1-255 characters))

Specify the absolute pathname of the column name specification file. This option is required in the following cases:

Number of columns on the source system and the target system are not the same.

Columns are resorted.

Data is extracted with a line-by-line interface.

Columns of the SGMLTEXT type are extracted.

For details about how to specify a column name specification file, see 4.2.4 Contents of files specified with the xtrep command.

-w table-expression-specification-filename

~ <pathname> ((1-255 characters))

Specify the absolute pathname of the table expression specification file. This option is required in the following cases:

Rows for extraction are selected on the basis of specified conditions.

Extraction results are sorted.

For details about how to specify a table expression specification file, see 4.2.4 Contents of files specified with the xtrep command.

-v null-value-information-filename

~ <pathname> ((1-255 characters))

Specify the absolute pathname of the null value information file. Specify a null value information file in the following cases:

The default null value is to be changed.

The data format and null value import method need to be specified in order to output repetition columns to a file.

For details about how to specify the default null value and the null value information file when this option is omitted, see (3) in 4.2.4 Contents of files specified with the xtrep command. For details about the data format for repetition columns and the null value import method, see (6) in 3.1.1 Extracting selected data.

-b LOB-input-file-storage-directory-name

~ <pathname> ((1-70 characters))

Specify the name of the directory for storing LOB input files.

If the extracted data contains LOB data, this option specifies the name of the directory for storing the LOB input files that are created to process the LOB data on the data import or file creation system. To store BLOB-column data in the same output file as for non-BLOB data without creating LOB input files, specify the XTLOBKIND environment variable.

To retain the LOB input file storage directory after completion of import processing, specify the -o option; to delete the LOB input file storage directory upon completion of import processing, specify the -O option. The -o and -O options are mutually exclusive.

If you specify the -o or -O option and a file to be created already exists, use the -y option to specify how to handle the file.

If the -R option is specified, HiRDB Dataextractor creates the LOB input file storage directory at the following host on the file creation system:

-h option specified: Host specified with the -h option

-h option omitted: Host specified in the XTHOST environment variable

If the -R option is omitted, HiRDB Dataextractor creates the LOB input file storage directory at the host located at the following HiRDB server on the target system:

HiRDB/Single Server: Single server

HiRDB/Parallel Server:
-f option specified: FES or BES specified with the -f option
-f option omitted: FES or BES that is the default when the -f option is omitted

When this option is omitted, HiRDB Dataextractor creates files with unique names in the /opt/HIRDBXT/spool directory. For details, see Table 2-3 Directories and files created by HiRDB Dataextractor.

Note

If the specified value contains a back slash (\), enclose the specified value in double quotation marks (").

-q error-data-filename[,output-lines-count]

error-data-file-name ~ <pathname> ((1-255 characters))

To output invalid row data to an error data file, specify the name of the error data file that is to be created by HiRDB's database load utility (pdload).

output-lines-count ~ <unsigned integer> ((1-4294967295))

Specify a maximum number of output lines of erroneous row data. If you omit this information, pdload assumes 100.

The error data file is created at the host located at the following server on the importing HiRDB system:

HiRDB/Single Server: Single server

HiRDB/Parallel Server:
-f option specified: FES or BES specified with the -f option
-f option omitted: FES or BES that is the default when the -f option is omitted

The created error data file will remain after the import processing is completed, so you can modify the row data in the error data file and use the file as an input data file for pdload.

When this option is omitted, erroneous row data is not output. If the specified error data file already exists, HiRDB Dataextractor overwrites the existing file. The name of the error data file is determined by this option and the value set in the XTTMPDIR environment variable. Table 4-2 shows the name of the error data file to be created.

Table 4-2 Name of the error data file to be created

-q option | XTTMPDIR | Name of error data file
Specified | Specified | $XTTMPDIR/error-data-filename
Omitted | /opt/HIRDBXT/spool/error-data-filename
Omitted | -- | -- (Not created)

Notes

The total length of the XTTMPDIR environment variable and the filename must not exceed 255 characters.

This option is applicable only if the HiRDB Dataextractor on the import or file creation system supports this feature. If the feature is not supported, HiRDB Dataextractor outputs the JXU7001E message and results in an error on the import or file creation system.

-x shell-script-filename

~ <pathname> ((1-255 characters))

To execute a user-created shell script after file creation, specify the absolute pathname of the shell script file. This option is applicable only when the -R option is specified.

When this option is specified, HiRDB Dataextractor processing is placed on hold until the shell script processing is completed. If the shell script's exit status is not 0, HiRDB Dataextractor outputs the JXU7010E error message.

The specified shell script must satisfy the following conditions:

The shell script is created at a server machine on the file creation system.

HiRDB Dataextractor's executor specified in /etc/inetd.conf on the file creation system can execute the shell script.

The shell script's exit status is in the range of -128 to 127.

The shell script can use the standard output and standard error output, but not the standard input.

[authorization-identifier.]table-identifier

Specify the table that is to be subject to data extraction. When the authorization identifier is omitted, HiRDB Dataextractor assumes the command executor's authorization identifier in the PDUSER environment variable.

Notes

You must specify this information at the end of the xtrep command.

The specified authorization identifier and table identifier are assumed to be in all uppercase letters. To have them handled as being case sensitive, separately enclose each of them (authorization identifier and table identifier) in double quotation marks ("), and then enclose them each separately or both together in single quotation marks (').

If the table identifier contains a space, enclose the entire table identifier in double quotation marks (") and then close it in single quotation marks (').

Examples

The following specifications are both regarded as USER01.TABLE01:

user01.table01

"user01"."table01"

The following specifications are both regarded as user01.table01:

'"user01"."table01"'

'"user01"'.'"table01"'

(6) Combination of xtrep command options

The valid xtrep command options depend on the facility to be used after data extraction. To import extracted data into a table, you must omit the -R option; to only create a file without importing data into a table, you must specify the -R option. Table 4-3 shows the combinations of xtrep command options.

Table 4-3 Combinations of xtrep command options

Option
Facility to be used

Format
Specified information
Import facility
File creation facility

-r
Name of table to be subject to data import
O
N

-R
File creation
I
F

-o
Output filename or directory name (when not deleted)
O
R

-O
Output filename or directory name (when deleted)
O
N

-y
Whether or not to overwrite file
O
O

-j
Name of RDAREA to be subject to data storage
O
N

-h
Name of host to be subject to processing
O
O

-H
Name of host to be subject to data import (when the hosts on source and target systems use different LANs)
O
N

-p
Port number subject to processing
O
O

-f
FES or BES at the destination
O
N

-d
Storage method (value specified with pdload)
O
N

-i
Index creation mode (value specified with pdload)
O
N

-I
Names of pdload control information environment variables, pdload command line information environment variables, and pdload control information file's source statement information environment variables
(XTPDCFxxxxx, XTLPRMxxxxx, XTPDSRxxxxx)
O
N

-l
Log acquisition mode (value specified with pdload)
O
N

-L
Name of import information file
O
O

-n
Number of batch output pages (value specified with pdload)
O
N

-z
0-byte characters storage (value specified with pdload)
O
N

-e
Name of error log file
O
O

-m
Progress message output interval
O
O

-g
Lock mode
O
O

-s
Name of column name specification file
O
O

-w
Name of table expression specification file
O
O

-v
Name of null value information file
O
O

-b
Name of LOB input file storage directory
O
O

-q
Name of error data file and number of output lines
O
N

-x
Name of shell script file
N
O

*
Name of table to be subject to data extraction
R
R

F: Option that specifies the facility that is to be used.

I: Must not be specified when data is to be imported into a table. When the -R option is specified, HiRDB Dataextractor executes the file creation facility and does not import data into a table.

R: Required option (if omitted, HiRDB Dataextractor outputs the JXU7300E message, resulting in an error).

O: Optional option.

N: Option that cannot be specified (if specified, HiRDB Dataextractor outputs the JXU7306E or JXU7307E message, resulting in an error).

* Specify [authorization-identifier.]table-identifier.

4.2.3 Additional data extraction and import functions

This subsection describes the following data extraction and import functions:

SQL user specification function during data extraction

Loader parameter specification function

Character code conversion function

Organization of this subsection

(1) SQL user specification function during data extraction

(2) Loader parameter specification function

(3) Character code conversion function

(1) SQL user specification function during data extraction

HiRDB Dataextractor enables the user to specify desired information in the following SQL statements that are issued when data is extracted from a HiRDB table.

LOCK TABLE statement

SELECT statement

Table 4-4 explains the scope of this function.

Table 4-4 Scope of the SQL user specification function during data extraction

Data linkage type | Source | Target | Applicability
XDM/XT linkage | XDM/RD | HiRDB | --
Sequential dataset | --
HiRDB | XDM/RD | Y
Sequential dataset | Y
HiRDB Dataextractor linkage | HiRDB | HiRDB | Y
Binary-format file | Y
DAT-format file | Y

Y: Applicable

--: Not applicable to HiRDB Dataextractor alone.

For details, see the manual VOS3 Database Extraction Program XDM/XT.

(a) Use with XDM/XT linkage

To use this function with XDM/XT linkage, the following specifications are required:

XDM/XT's JXUMCTL control statement
RDBDEF and EXTRACT statements

HiRDB Dataextractor's environment variable information setup file (source system)

Table 4-5 lists the environment variables that must be specified in the environment variable information setup file.

Table 4-5 Environment variables to be set to use the SQL user specification function (applicable to XDM/XT linkage)

Environment variable | Specification
PDHOST | As required*
PDNAMEPORT | As required*
XTEXTRACTDB | As required
XTLCKxxxx | As required
XTTBLxxxx | As required
XTCLMxxxx | As required
XTWHExxxx | As required

As required: Specify as appropriate.

* This environment variable is required when the RDBDEF statement is specified in XDM/XT's JXUMCTL control statement.

For details about the environment variables, see 2.2.3 Specifying environment variables.

(b) Use with HiRDB Dataextractor linkage

To use this function with HiRDB Dataextractor linkage, you execute the xtrep command.

Environment variable

If you use this function, make sure that the following environment variable is specified in the source system:

XTSQL

For details about the environment variables, see 2.2.3 Specifying environment variables.

Command options

Table 4-6 describes the options whose specification is related to this function.

Table 4-6 Specification of xtrep command options when the SQL user specification function is used during data extraction

Command | Option | Value | Import to HiRDB | Binary or DAT file creation
XTSQL | XTSQL
0 | 1 | 0 | 1
xtrep | -g | -- | O | M | O | M
lock-information-file
-r | [authorization-identifier,]table-identifier | O | M | N | N
-R | -- | N | N | M | M
{bin|dat}
-s | column-name-specification-file-name | O | O | O | O
-w | table-expression-specification-file-name | O | N | O | N
[authorization-identifier,]table-identifier | -- | M | N | M | N
table-expression-specification-file | -- | N | M | N | M

M: Mandatory

O: Optional

N: Not specifiable

--: Not specified

-g [lock-information-file-name]
The combination of this option and the XTSQL environment variable is used to perform lock control on the table from which data is extracted. Specification of this option is mandatory when 1 is specified in the XTSQL environment variable.
The following table provides the details of the lock information file specification:

XTSQL | -g option | Action
0 | Omitted | -- | Issue LOCK TABLE using the table name entered on the command line.
Specified | No value specified | Do not issue LOCK TABLE.
Value specified | Issue LOCK TABLE based on information in the lock information file.
1 | Omitted | -- | Error
Specified | No value specified | Do not issue LOCK TABLE.
Value specified | Issue LOCK TABLE based on information in the lock information file.

-r [authorization-identifier,]table-identifier
This option or the -R option must be specified when 1 is specified in the XTSQL environment variable.

-R [{bin|dat}]
This option or the -r option must be specified when 1 is specified in the XTSQL environment variable.

-s column-name-specification-file-name
If necessary, specify the absolute path of the column name specification file.

-w table-expression-specification-file-name
This option cannot be specified when 1 is specified in the XTSQL environment variable.

[authorization-identifier,]table-identifier
Specify this option when the XTSQL environment variable is omitted or 0 is specified in the XTSQL environment variable.

table-expression-specification-file-name
Specify this option when 1 is specified in the XTSQL environment variable.

For details about these options, see 4.2.2 xtrep command.

File specification method

This subsection describes the specification of files in options.

Lock information file:
This file specifies the lock options in the LOCK TABLE statement.
Specify the file contents as follows, as appropriate to the specification of XTSQL:

XTSQL | Specification
0 | Specify the lock options that follow LOCK TABLE table-name
1 | Specify the lock options that follow LOCK TABLE

Table expression specification file:
This file specifies the table expression in the SELECT statement.
Specify the file contents as follows, as appropriate to the specification of XTSQL:

XTSQL | Specification
0 | Specify the table expression that follows FROM table-name in the SELECT statement
1 | Specify the table expression that follows FROM in the SELECT statement

Note

When 1 is specified in the XTSQL environment variable, no column name can be specified in the null value information file. If you specify information such as a default null value or data format of repetition columns, specify applicable field numbers. Specifying column names results in an error.

(2) Loader parameter specification function

When data is imported into a HiRDB table, HiRDB Dataextractor starts HiRDB's database load utility (pdload). The loader parameter specification function enables you to specify desired parameters for pdload.

Table 4-7 explains the scope of this function.

Table 4-7 Scope of loader parameter specification function

Data linkage type | Source | Target | Applicability
XDM/XT linkage | XDM/RD | HiRDB | Y
Sequential data set | Y
HiRDB Dataextractor linkage | HiRDB | HiRDB | Y

Y: Applicable

(a) Use with XDM/XT linkage

To use this function with XDM/XT linkage, the following specifications are required:

XDM/XT's JXUMCTL control statement
HIRDDEF statement's PDLODPRM operand
LOAD statement's LPRMPATH and PDSRPATH operands

HiRDB Dataextractor's environment variable information setup file (target system)
XTLPRMxxxx
XTPDSRxxxx
Specify the environment variables as required. For details about the environment variables, see 2.2.3 Specifying environment variables.

(b) Use with HiRDB Dataextractor linkage

To use this function with HiRDB Dataextractor linkage, execute the xtrep command.

Environment variables

When you use this function, specify the following environment variables as required in the target system's environment variable information setup file:

XTLPRMxxxx

XTPDSRxxxx

For details about the environment variables, see 2.2.3 Specifying environment variables.

Command options

Table 4-8 describes the options whose specification is related to this function.

Table 4-8 Specification of the xtrep command options when the loader parameter specification function is used

Command | Option | Value | Requirement
xtrep | -d | -- | 1'
-f | server-name | O
-i | {c|s|n|x} | 1'
-I | XTPDCFxxxx | O
XTLPRMxxxx | M, 1
XTPDSRxxxx | M, 2
-j | RDAREA-name | O
-l | {a|p|n} | 1'
-n | buffer-sectors-count | 1'
-q | error-data-file-name,count | 2'
-v | null-value-information-file | O
-z | -- | 1'

M: One of these items is required in order to use this function.

O: This item is optional.

1, 1': These items are mutually exclusive.

2, 2': These items are mutually exclusive.

-I [XTPDCFxxxx][,XTLPRMxxxx][,XTPDSRxxxx]
Specify at least one value. You can specify multiple values in any order by using the comma (,) as the delimiter.

XTPDCFxxxx (name of pdload control information environment variable)

Specify this information as necessary. For details about the environment variables, see 2.2.3 Specifying environment variables.

XTLPRMxxxx (name of pdload command line information environment variable)

To use this function, ensure that either the XTLPRMxxxx or the XTPDSRxxxx environment variable is specified.

Notes

When you specify this environment variable, none of the following options can be specified:
-d option
-i option
-l option
-n option
-z option

When the name of this environment variable is specified, HiRDB Dataextractor does not specify any parameter other than the table name, control information file name, -b, -k, -v, -W, or -c option when pdload starts; therefore, specify all necessary options in the pdload command line information file.

XTPDSRxxxx (name of pdload control information file's source statement information environment variable)

To use this function, ensure that either the XTLPRMxxxx or the XTPDSRxxxx environment variable is specified.

Note

When you specify this environment variable, do not specify the -q option, because it cannot be specified.

(3) Character code conversion function

This function converts the character codes of the extracted data according to specified environment variables and then imports the data.

Table 4-9 explains the scope of this function.

Table 4-9 Scope of the character code conversion function

Data linkage type | Source | Target | Applicability
XDM/XT linkage | XDM/RD | HiRDB | --
Sequential dataset | --
HiRDB | XDM/RD | --
Sequential dataset | --
HiRDB Dataextractor linkage | HiRDB | HiRDB | Y
Binary-format file | Y
DAT-format file | Y

--: Not applicable to HiRDB Dataextractor.

For details, see the manual VOS3 Database Extraction Program XDM/XT.

Y: Applicable

For details about the character code sets that can be converted by this function, see 3.1.4 Converting the character codes of extracted data.

(a) Using the character code conversion function

By specifying environment variables and a null value information file, you can convert the character codes during data import processing.

Environment variables

Table 4-10 shows the environment variables that are required to use this function. For details about the location where the environment variables are to be set, see 2.2.3 Specifying environment variables.

Table 4-10 Environment variables required to use the character code conversion function

Environment variable
Source
Target
File creation system

XTLOCALE
As required
As required
As required

XTUNDEF

As required
As required

As required: Specify as appropriate

XTLOCALE

Specify a system of character codes used by the source and target systems. For details about the environment variables, see 2.2.3 Specifying environment variables.

The following table shows the combinations of environment variable values for the source and target systems:

Source | Target
sjis | euc | utf-8 | unknown
sjis | -- | Y | Y | --
euc | Y | -- | Y | --
utf-8 | Y | Y | -- | --
unknown | -- | -- | -- | --

Y: Character codes specified by the source are converted to the character codes specified by the target.

--: Character codes are not converted.

XTUNDEF

Specify how to handle undefined codes. For details about the environment variables, see 2.2.3 Specifying environment variables.

Null value information file

To specify whether or not the character codes are to be converted for each column, specify a null information file in the -v option of the xtrep command.

For details about how to specify this file, see 4.2.4 Contents of files specified with the xtrep command.

(b) Converting Gaiji codes

To convert Gaiji characters of the SJIS or EUC character code sets, use a mapping table for converting character codes. The base mapping table that is used for conversion is installed automatically when HiRDB Dataextractor is installed. For details about the directory and file names, see (2) Directories and files created by HiRDB Dataextractor in 2.2.2 Installing HiRDB Dataextractor.

In the initial status, no Gaiji codes have been defined in this base mapping table. If you use Gaiji characters during conversion, you must update character code conversion mapping tables.

When you update mapping tables, verify that both the following mapping tables are updated, so that consistency is maintained:

Mapping table used to convert the source system's locale to the target system's locale

Mapping table used to convert the target system's locale to the source system's locale

Editing and referencing a mapping table for converting character codes

You use the xtccnvedt command to define Gaiji codes in a mapping table or to reference a table's contents.

HiRDB Dataextractor must not be running while a mapping table is being edited.

Function

On the basis of the mapping table that was provided during installation of HiRDB Dataextractor, create a new mapping table in the following directory:

/opt/HIRDBXT/lib/usermap/

If a mapping table already exists in this directory, it will be overwritten.

Execution environment

Execute the command as superuser on the target machine to which data is to be imported.

Command

To update a mapping table

xtccnvedt -w
         -f {sjis|euc|ucs2}
         -t {sjis|euc|ucs2}
         -d conversion-definition-file-name

To reference a mapping table

xtccnvedt -r
         -f {sjis|euc|ucs2}
         -t {sjis|euc|ucs2}
         -o output-file-name
        [-s output-start-code]
        [-e output-end-code]

Options

To update a mapping table

-w
Specify this option to update a mapping table.

-f {sjis|euc|ucs2}
Specify the source code set:
sjis: SJIS character codes
euc: EUC character codes
ucs2: UTF-8 character codes

Note

If the character code set is UTF-8, specify ucs2.

-t {sjis|euc|ucs2}
Specify the target code set:
sjis: SJIS character codes
euc: EUC character codes
ucs2: UTF-8 character codes

Note

If the character code set is UTF-8, specify ucs2.

-d conversion-definition-file-name
Specify the name (1-127 characters) of the conversion definition file that defines the information to be updated in the mapping table. If you specify a relative path, the command assumes that it is relative to the current directory.

To reference a mapping table

-r
Specify this option to reference a mapping table.

-o
Specify the name (1-127 characters) of the file to which the results of referencing the mapping table are to be output. If you specify a relative path, the command assumes that it is relative to the current directory.
The results of referencing the mapping table are output in the format defined in the conversion definition file in the order of 1-byte, 2-byte, and 3-byte code character strings in ascending order of the source character codes.
The command converts only those codes whose target codes have been defined; it does not output any codes for which no target code has been defined.

-s output-start-code
Specify as a hexadecimal character string the source character code where referencing is to begin. If this option is omitted, the command starts referencing at the beginning of the mapping table.

Note

Specify output-start-code as follows:

Express a 1-byte code as 2 characters, a 2-byte code as 4 characters, and a 3-byte code as 6 characters (applicable only when the source codes are EUC). An error results if the number of characters does not match any of these.

If a specified 3-byte code does not begin with 8f, an error results.

If the specified value is greater than output-end-code specified in the -e option, an error results.

-e output-end-code
Specify as a hexadecimal character string the source character code where referencing is to end. If this option is omitted, the command references through the end of the mapping table.

Note

Specify output-end-code as follows:

Express a 1-byte code as 2 characters, a 2-byte code as 4 characters, and a 3-byte code as 6 characters (applicable only when the source codes are EUC). An error results if the number of characters does not match any of these.

If a specified 3-byte code does not begin with 8f, an error results.

If the specified value is smaller than output-start-code specified in the -s option, an error results.

Note

The following table shows the code set combinations that can be specified with the -f and -t options.

-f option | -t option | Map file subject to processing
sjis | euc | jis2euc.map
ucs2# | jis2ucs2.map
euc | sjis | euc2jis.map or eucg2j.map
ucs2# | euc2ucs2.map or eucg2u.map
ucs2# | sjis | ucs22jis.map
euc | ucs22euc.map

Note: If the specified source and target code sets are the same, the command does not update the character code conversion mapping table.

#: If the character code set is UTF-8, specify ucs2.

Conversion definition file

In the conversion definition file, you specify in the following format a source character code in the character code conversion mapping table that is to be updated and the target character code:

source-character-code,target-character-code

Rules

Define 1 entry per line.

Specify the source and target character codes as hexadecimal character strings (a-f are not case-sensitive).

A line beginning with the hash mark (#) is handled as a comment. To specify a comment following a conversion definition, you must specify at least 1 space or tab between the definition and the hash mark.

Express a 1-byte code as 2 characters, a 2-byte code as 4 characters, and a 3-byte code as 6 characters (applicable only to EUC character codes). An error results if the number of characters does not match any of these.

If a specified 3-byte code does not begin with 8f, an error results.

The command ignores any specification following the first space after the target-character-code.

The command ignores any space or tab before and after each code.

(c) Code conversion error handling procedure

The code conversion error handling procedure depends on the cause of the error, as described below.

(i) When the resulting data length is greater than the size of the receiving area

The command discards the excess data and sets the remaining data.

(ii) When the source data (in units of columns) ends with part of a 2- or 3-byte code

When the target attribute is fixed-length
The command sets the data up to the erroneous data and sets spaces (0x20) in the remaining area.

When the target attribute is variable-length
The command sets data up to the erroneous data.

When the command detects a conversion error, it issues an error message (JXU7230I) and processes the column following the erroneous column. If the number of conversion error records reaches the cancellation count, the command issues an error message (JXU7230E) and terminates processing.

4.2.4 Contents of files specified with the xtrep command

Among the files specified with the xtrep command, this section describes the contents of the following files:

Column name specification file

Table expression specification file

Null value information file

Output file

Import information file

Lock information file

Organization of this subsection

(1) Column name specification file

(2) Table expression specification file

(3) Null value information file

(4) Output file

(5) Import information file

(6) Lock information file

(1) Column name specification file

Specify in the column name specification file a selection expression for the SELECT statement. For details about how to specify a selection expression with the SELECT statement, see the HiRDB SQL Reference manual.

Notes

If a column name contains a space or hyphen (-), enclose the column name in double quotation marks (").

To have a column name handled as being case sensitive, enclose it in double quotation marks ("). If you do not enclose it in double quotation marks, the column name is assumed to be all uppercase letters.

To extract a column of the SGMLTEXT type, specify the extracts abstract data type function.

The following is the format of the extracts abstract data type function:

Format

extracts (column-name)

(2) Table expression specification file

Specify in the table expression specification file the following clauses for the SELECT statement:

WHERE clause

ORDER BY clause

For details about how to specify the WHERE and ORDER BY clauses in the SELECT statement, see the HiRDB SQL Reference manual.

Notes

If a value in the table expression contains a space or hyphen (-), enclose the value in double quotation marks (").

To have a value in the table expression handled as being case sensitive, enclose the value in double quotation marks ("). If you do not enclose it in double quotation marks, the value is assumed to be all uppercase letters.

For details about the data type combinations that can be specified in the table expression specification file, see Tables 3-7 and 3-8.

If you specify the ORDER BY clause and attributes or character codes are converted during extraction, the sort order in the target system may be different.

(3) Null value information file

Specify the null value information file in the following cases:

The default null value is to be changed.
If you want to store the null value in a column that is subject to data import, you can use a null value information file to change the null value. If an extract data item matches the specified value, HiRDB Dataextractor stores the null value in the corresponding table column.
In the case of file creation, specify the default null value to be stored in the file when the extracted data contains a null value.
Table 4-12 shows the default null value that is used by HiRDB Dataextractor based on the value specified in the null value information file and when the null value information file is omitted (-v option is omitted).

The data format and null value import method must be specified in order to output repetition columns to a file.
For details about the data format and null value import method for repetition columns, see (6) in 3.1.1 Extracting selected data.

Format

{column-name|field-number=NUM}
 [={HIGH|LOW|ZERO|SPACE|('literal')|
         (X'hexadecimal-literal')}]
     [,ARRAY={FF|FV|VV}[,NULLELM={C|E}]]
   [,{NOCODECONV|CODECONV}]

Description

column-name

Specify the name of the column whose default null value is to be changed.

Importing data into a HiRDB table
Specify the column name of the table on the target system.

Only creating a file
Specify the name of the column of the table on the source system.

field-number=NUM

Specify the sequence number, from the beginning, of the column whose default null value is to be changed. The permitted value range is 1-99999.

When importing into a HiRDB table
Specify the sequence number from the beginning of the target table definition.

When only creating a file
-s option omitted: Specify the sequence number from the beginning of the source table definition.
-s option specified: Specify the sequence number, from the beginning, of the column name specified in the column name specification file.

{HIGH|LOW|ZERO|SPACE|('literal')|(X'hexadecimal-literal')}

Specify the default null value.

For the value that is used by HiRDB Dataextractor based on this specification, see Table 4-11.

ARRAY={FF|FV|VV}

Specify the data format to be used to store the repetition column in the file.

For the permitted combinations of the ARRAY and NULLELM values, see Table 4-12.

FF

The number of elements is not at the beginning of a column and there is data for all column elements.

FV

The number of elements is at the beginning of a column and there is data for all column elements.

VV

The number of elements is at the beginning of a column and there are as many data items as there are elements.

NULLELM={C|E}

In the case of storing a repetition column in the file, specify how to handle the null value (null value import method) if all elements are the null value.

For the permitted combinations of the ARRAY and NULLELM values, see Table 4-12.

C

When there is no data for any element, handle the entire column as the null value.

E

When there is no data for any element, handle each element as a null value.

{NOCODECONV|CODECONV}

For each column, specify whether or not the codes are to be converted.

NOCODECONV: Specify this value when you are not using the character code conversion function. This value is effective only when the XTLOCALE environment variable is specified for codes to be converted.

CODECONV: Specify this value when you are using the character code conversion function. This value is effective only when the XTLOCALE environment variable is specified for codes to be converted.

Note

If all the conditions listed below are satisfied, make sure that this value is specified for SGMLTEXT columns; if this value is omitted, the SGMLTEXT type will not be subject to character code conversion processing:

Character codes are to be converted.

Data is to be extracted and only file creation is to be performed (without importing to a HiRDB table).

The data to be extracted contains the SGMLTEXT type.

Rules

Specify information for one column per line. To specify information about multiple columns, specify as many lines as there are columns.

A comment begins with the number sign (#) and ends at the end of the line.

If a column name contains a space or hyphen (-), enclose the column name in double quotation marks (").

To have a column name handled as being case sensitive, enclose it in double quotation marks ("). If you do not enclose it in double quotation marks, the column name is assumed to be all uppercase letters.

When you specify a literal, check that its length does not exceed 255 bytes. Do not specify ') (a single quotation mark immediately followed by a close parenthesis) in the literal.

In the case of data import into a HiRDB table, if a target column has the non-NULL attribute, the default null value is stored as is as the data.

If the column on the source system has the non-NULL attribute during file creation, HiRDB Dataextractor ignores this option.

For each abstract data type column, only a value specifying whether or not to use the code conversion function (NOCODECONV or CODECONV) can be specified.

For details about how to specify the data format of repetition columns and the null value import method, see (6) in 3.1.1 Extracting selected data.

Because the default null value is not subject to character code conversion, if you are outputting a binary file, use the target system's character codes to specify the literal.

Character codes are not converted when the following data types are converted; therefore, if conversion is needed, specify CODECONV:
(VAR)CHAR to BINARY type
M(VAR)CHAR to BINARY type

To specify a hexadecimal literal for the numeric attribute, use the target system's endian expression.

To specify a hexadecimal literal for the FLT or SFLT attribute, observe the IEEE floating point standard.

When a DAT file is to be created, FV cannot be specified in ARRAY.

If the target table contains a variable-length character string, neither FF nor FV can be specified in this environment variable.

When a binary or DAT file is to be created, NULLEM cannot be specified.

Neither ARRAY nor NULLEM can be specified for normal columns.

Notes

If a hexadecimal literal is specified for the FLT or SFLT attribute, HiRDB Dataextractor may correct the value in order to import the null value correctly.

The specification rules for the null value information file differ depending on the specification in the XTNLDFLT environment variable. For details about the specification rules, see Table 4-13. For details about the relationship between the specified value of the XTNLDFLT environment variable and the default null value, see Table 4-14.

Example

CLM01=HIGH                        #INT
CLM02=LOW                         #DATE
CLM03=('FFFF')                    #CHAR(4)
CLM04=SPACE,ARRAY=FV,NULLELM=E    #CHAR(4)
CLM05, NOCODECONV
CLM06=(X'A4A2')

Table 4-11 Default null value

Data type
-v option omitted⁹
-v option value

HIGH
LOW
ZERO
SPACE
Literal
Hexadecimal literal

INTEGER
-2147483648​
2147483647​
-2147483648​
0
N
N
X'hexadecimal-literal' (4 bytes)

SMALLINT
-32768
32767
-32768
0
N
N
X'hexadecimal-literal' (2 bytes)

DECIMAL(p,s)
-99...99
99...99
-99... 99
0¹
N
N
X'hexadecimal-literal'((p + 1)/2 bytes)

FLOAT
²
³
²
0
N
N
X'hexadecimal-literal' (8 bytes)

SMALLFLT
⁴
⁵
⁴
0
N
N
X'hexadecimal-literal' (4 bytes)

CHAR(n)
VARCHAR(n)
MCHAR(n)
MVARCHAR(n)
n < 4
n bytes of '#' (single bytes)
N
N
N
n bytes of spaces
(single bytes)
literal
(n bytes)
X'hexadecimal-literal' (n bytes)

n 4
4 bytes of '#' (single bytes)
N
N
N
4 bytes of spaces
(single bytes)
literal
(max. 255 bytes)
X'hexadecimal-literal' (max. 127 bytes)

NCHAR(n)
NVCHAR(n)
n < 2
(n = 1)
2 bytes of '#' (double bytes)⁶
N
N
N
2 bytes of a space (double bytes)⁶
literal
(2 bytes)
X'hexadecimal-literal'(2n bytes)

n 2
4 bytes of '##'
(double bytes)⁶
N
N
N
4 bytes of spaces (double bytes)⁶
literal
(max. 254 bytes)
X'hexadecimal-literal' (max 127 bytes)

DATE
0001- 01-01
9999- 12-31
0001- 01-01
N
N
N
X'hexadecimal-literal' (4 bytes)

INTERVAL YEAR TO DAY
-9999 yrs, 11 mos, 99 days
9999 yrs, 11 mos, 99 days
-9999 yrs, 11 mos, 99 days
0000 yrs, 00 mos, 00 days
N
N
X'hexadecimal-literal' (5 bytes)

TIME
00:00:00
23:59:59
00:00:00
N
N
N
X'hexadecimal-literal' (3 bytes)

INTERVAL HOUR
TO SECOND
-99 hrs, 59 mins, 59 secs
99 hrs, 59 mins, 59 secs
-99 hrs, 59 mins, 59 secs
00 hrs, 00 mins, 00 secs
N
N
X'hexadecimal-literal' (4 bytes)

BLOB
XTNL0
N
N
N
N
N
N

BINARY(n)
n < 128
X'00...00'
(n bytes)
X'FF...FF' (n bytes)
X'00...00'
(n bytes)
N
N
N
X'hexadecimal-literal ' (n bytes)

n 128
X'00...00'
(127 bytes)
X'FF...FF' (127 bytes)
X'00...00'
(127 bytes)
N
N
N
X'hexadecimal-literal ' (max 127 bytes)

TIMESTAMP(n)
0001- 01-01 at 00:00:00.000000⁷
9999- 12-31 at 23:59:59.999999⁷
0001- 01-01 at 00:00:00.000000⁷
N
N
N
X'hexadecimal-literal ' (7 + (n/2) bytes)

N: Cannot be specified.

yrs: years

mos: months

hrs: hours

mins: minutes

secs: seconds

¹ The value 0 indicates a value with a sign part (C: positive sign).

² -1.7976931348623157e + 308

³ 1.7976931348623157e + 308

⁴ -3.4028234663852886e + 38

⁵ 3.4028234663852886e + 38

⁶ Regardless of the character code set, X'8140'is assumed for the space and X'8194' for '#'.

⁷ The number of decimal places depends on the definition (0-6 decimal places).

Table 4-12 Permitted combinations of ARRAY and NULLELM

Function | Specified value | Permitted | Processing
Source | Target | ARRAY | NULLELM
HiRDB | HiRDB | FF | -- | Y | Continues
C
E
FV | --
C | N | Error
E
VV | -- | Y | Continues
C | N | Error
E
Binary file | FF | -- | Y | Continues
C | N | Error
E
FV | -- | Y | Continues
C | N | Error
E
VV | -- | Y | Continues
C | N | Error
E
DAT file | FF | -- | Y | Continues
C | N | Error
E
FV | --
C
E
VV | -- | Y | Continues
C | N | Error
E

--: Not specified

Y: Permitted

N: Not permitted

Table 4-13 Null-value information file specification rules (applicable to data extraction from a HiRDB table)

Specification in the null value information file
XTNLDFLT environment variable

0 or 1
2

Import to HiRDB
File creation
Import to HiRDB
File creation

Binary format
DAT format
Binary format
DAT format

column-name|
field-number=NUM
M
M
M
M
M
M

=default-null-value
Y
Y
Y
N
N
N

ARRAY=
FF
Y
Y
Y
N
N
Y

FV
Y
Y
N
N
N
N

VV
Y
Y
Y
N
N
Y

NULLELM={C|E}
Y
N
N
N
N
N

NOCODECONV|CODECONV
Y
Y
Y
Y
Y
Y

M: Must be specified

Y: May be specified

N: Cannot be specified

Table 4-14 Relationship between the specified environment variable value and the default null value

Data type
Default value when -v option is omitted

Value specified in XTNLDFLT environment variable

0
1

INTEGER
-2147483648​
Same as at left

SMALLINT
-32768
Same as at left

DECIMAL
-99...99
X'FF...FF'

FLOAT
¹
Same as at left

SMALLFLT
²
Same as at left

CHAR(n)
VARCHAR(n)
MCHAR(n)
MVARCHAR(n)
When n 4:
n bytes of '#'
When n > 4:
4 bytes of '#'
Same as at left

NCHAR(n)
NVARCHAR(n)
When n 2:
n characters of '#' (double bytes)
When n > 2:
2 characters of '#' (double bytes)
Same as at left

DATE
0001-01-01
X'FFFFFFFF'

INTERVAL YEAR TO DAY
-9999 years, 11 months, and 99 days
X'FFFFFFFFFF'

TIME
00:00:00
X'FFFFFF'

INTERVAL HOUR TO SECOND
-99 hours, 59 minutes, and 59 seconds
X'FFFFFFFF'

BLOB
XTNL0
Same as at left

BINARY(n)
When n <128:
X'00...00' (n bytes)
When n 128:
X'00...00' (127 bytes)
Same as at left

TIMESTAMP(n)
0001-01-01 at 00: 00:00.000000 ³
X'FF...FF'
(7 + (N)/2 bytes)

¹ -1.7976931348623157e + 308

² -3.4028234663852886e + 38

³ The number of decimal places depends on the definition (0-6 decimal places).

(4) Output file

An output file is used to store extracted data. This section explains the format used by HiRDB Dataextractor to store extracted data in an output file. The specification format for an output file is based on the format of input files used by HiRDB's database load utility. There are two formats for an output file:

DAT format

Binary format

(a) DAT format

When you use the DAT format, specify the extracted data as character string data. The specification method is described below:

Each line in the file corresponds to one row of table data. Each line must end with a linefeed code.

Use a separator character between the column data items. You can specify the separator character to be used in the -R option. If you omit the -R option, HiRDB Dataextractor uses the comma (,) as the separator character.

If column data is the null value, do not specify it regardless of the data type (it is assumed that there is no data).

Table 4-15 shows the specification format of column data (DAT format) for each data type.

Table 4-15 Specification format of column data (DAT format)

Data type
Specification format of column data

Numeric data
INTEGER

Specify a numeric value in characters.

For a negative value, add a minus sign (-).

Specify a decimal point as integer.fraction.

Specify a floating point as mantissa-e exponent.

Integer (Example: -1234 ... 0 ... 1234)
Decimal point (Example: -1.56 ... 0 ... 1.56)
Floating point (Example: -2.4e+9 ... 0e0 ... 2.4e+9)

SMALLINT

DECIMAL

FLOAT

SMALLFLT

Character data
CHARACTER
Specify as a character string enclosed in double quotation marks (").
Example: "abcd" or "ABCD"
For a variable-length data type that has a length of 0, specify "".

VARCHAR

National character string data
NCHAR

NVARCHAR

Mixed character string data
MCHAR

MVARCHAR

Date data
DATE
Specify in the numeric format yyyy-mm-dd.
Example: January 1, 1998 1998-01-01

Date interval data
INTERVAL YEAR TO DAY
Specify in the numeric format [-]yyyymmdd. For a negative value, add a minus sign (-).
Example: 1111 years, one month, one day 11110101​.

Time data
TIME
Specify in the numeric format hh:mm:ss.
Example: 12:01:01 12:01:01

Time stamp data
TIMESTAMP(n)
n = 2, 4, 6
Specify in numeric format YYYY-MM-DD_hh:mm:ss.nnnnnn.
YYYY: year, MM: month, DD: day, hh: hour, mm: minute, ss: second, nnnnnn: 0-6 decimal places for the second. _: Single-byte space
(Example: 1997-10-15 at 15: 30:25.666666
1997-10-15 15:30:25.666666)

Time interval data
INTERVAL HOUR TO SECOND
Specify in the numeric format [-]hhmmss. For a negative value, add a minus sign (-).
Example: 1 hour, 1 minute, 1 second 010101.

Large object data
BLOB
Specify the absolute pathname of the LOB input file. A LOB input file is created for each LOB data item and stored in the LOB input file storage directory.

BINARY(n)
1 n 2,147,483,647

Enclose the data in double quotation marks (").

(Example: "abcdef")

Abstract data type
SGMLTEXT
Specify the absolute pathname of the original text file. A LOB input file is created for each LOB data item and stored in the LOB input file storage directory.

(b) Binary format

When you use the binary format, specify the extracted data in the storage format for the HiRDB database. The data format depends on the specification of the XTNLDFLT environment variable.

This subsection describes the data format that depends on the specification of the XTNLDFLT environment variable.

(i) When the XTNLDFLT environment variable is omitted or the value 0 or 1 is specified

Do not place any spaces between column data items.

Table 4-16 shows the specification format of column data (binary format) for each data item.

Table 4-16 Specification format of column data (binary format)

Data and parameter types
Column data specification format

Numeric data
INTEGER, SMALLINT

DECIMAL(m,n)
1 m 29
0 n 29
m n

FLOAT, SMALLFLT

Character string data, National character string data, Mixed character string data
CHARACTER(n) VARCHAR(n) MCHAR(n) MVARCHAR(n)

NCHAR(n) NVARCHAR(n)

Date data
DATE

Date interval data
INTERVAL YEAR TO DAY

Time data
TIME

Time stamp data
TIMESTAMP(n)
n = 0, 2, 4, 6

Time interval data
INTERVAL HOUR TO SECOND

Large object data
BLOB

BINARY(n)
1 n 2,147,483,647

Abstract data type
SGMLTEXT

Note: The real data length is set in binary. For data whose length is zero (0-byte characters), the value 0 is set as the real data length and the data is stored with no real data.

(ii) When the value 2 is specified in the XTNLDFLT environment variable

See Figure 4-1.

Figure 4-1 Specification format of data when 2 is specified in the XTNLDFLT environment variable (binary format)

Explanation

Line length: In the 4-byte area, set the length from the beginning to the end of the last column data.

Offset: In the 4-byte area, set the length from the beginning of one column data item to the beginning of another.

For null-value data, 0 is set, and neither column data, nor large object data, nor abstract data is created.

Column data: Table 4-17 describes the specification format for each type of column data.

Large object or abstract data: Use one of the data types listed below that consists of the column data section containing the size and the real data at the end. The real data is stored in the following order; if there are multiple data items with the same data type, they are stored in the order defined:

1. BINARY

2. SGMLTEXT

3. BLOB

Table 4-17 Specification format of column data (when 2 is specified in XTNLDFLT environment variable)

Data type
Column data specification format

Large object data
BINARY

The first 4 bytes contain a binary value indicating the length of the BINARY data, and the BINARY data is stored at the end of the record.

BLOB

Abstract data type
SGMLTEXT

The trailing 4 bytes of the first 8 bytes contain a binary value indicating the length of the LOB data, and the LOB data is stored at the end of the record.

Other
For the specification format of each data type, see Table 4-16. However, this does not apply when 2 is specified in the XTNLDFLT environment variable for repetition columns. For details, see Table 3-6 Data format of repetition columns during data import into a HiRDB table, and creation of a binary-format file when 2 is specified in the XTNLDFLT environment variable.

(5) Import information file

In the import information file, specify information about the columns whose data type is to be converted and the data types.

Specify the import information file in the following cases:

Extracted data is to be stored in a file only.
HiRDB Dataextractor outputs the data to a file with the specified data type. If the import information file (-L option) or data type is omitted, HiRDB Dataextractor assumes the data type of the extracted column when the data was stored.

The following data types are to be extracted and imported or stored in a file:

BLOB

BINARY

SGMLTEXT

Specify the maximum data length for each column. This economizes on buffer space because HiRDB Dataextractor uses the specified buffer size. If the import information file (-L option) or data type is omitted, the buffer size for the corresponding column depends on the XTLOBBUFSIZE environment variable.

Format

FORMAT
 {FIELD_NUM field-number|FIELD_NAME column-name}ATTR data-type
       [{FIELD_NUM field-number|FIELD_NAME}ATTR data-type]...

Description

FORMAT

Specifies that the data type is to be converted.

FIELD_NUM

Specify the sequence number, from the beginning, of the extracted column whose data type is to be converted.

-s option omitted

Specify the sequence number, from the beginning, in the target table definition.

-s option specified

Specify the sequence number, from the beginning, of the column name specified in the column name specification file.

The permitted value range is 1-99999. The same field number cannot be specified more than once.

FIELD_NAME

Specify the name of the extracted column whose data type is to be converted.

When the -s option is specified, this option cannot be specified, in which case specify FIELD_NUM.

The same column name cannot be specified more than once.

ATTR

Specify the data type.

Table 4-18 shows the data types that can be specified.

Notes

Specify the information for one column on a single line. To specify information about multiple columns, use as many lines as there are columns.

A line beginning with the hash mark (#) is regarded as a comment through the end of the line.

Enclose a column name containing a space or hyphen (-) in double quotation marks (").

To specify a case-sensitive column name, enclose the entire name in double quotation marks (").
A column name that is not enclosed in double quotation marks (") is treated as all upper-case letters.

When extracted data is imported and the buffer size specified in the import information file is greater than the size of the BLOB data type defined in the target system, HiRDB Dataextractor ignores this specification and uses the buffer equivalent to the defined length of the BLOB column.

Table 4-18 Data types permitted in ATTR

Permitted data type | Corresponding data type | File creation | Import to HiRDB
INT | INTEGER | Y | N
SINT | SMALLINT | Y | N
DEC(m,n)² | DECIMAL(m,n) | Y | N
FLT | FLOAT | Y | N
SFLT | SMALLFLT | Y | N
CHAR(n)³ | CHAR(n) | Y | N
VARCHAR(n)³ | VARCHAR(n) | Y | N
MCHAR(n)³ | MCHAR(n) | Y | N
MVARCHAR(n)³ | MVARCHAR(n) | Y | N
NCHAR(n)⁴ | NCHAR(n) | Y | N
NVARCHAR(n)⁴ | NVARCHAR(n) | Y | N
DATE | DATE | Y | N
TIME | TIME | Y | N
YEAR | INTERVAL YEAR TO DAY | Y | N
HOUR | INTERVAL HOUR TO SECOND | Y | N
BLOB(n[{K|M|G}])⁵ | BLOB(n[{K|M|G}]) | Y⁶ | Y⁷
SGMLTEXT(n{K|M|G})⁵ | SGMLTEXT | Y⁶ | Y⁶
BINARY(n)⁸ | BINARY(n) | Y⁶ | Y⁷
TIMESTAMP(n)⁹ | TIMESTAMP(n) | Y | N

Y: Can be specified.

N: Cannot be specified (the specification is ignored and the data type of the target system is assumed).

¹ For details about the data type combinations that can be specified, see Tables 3-7 and 3-8.

² m and n satisfy the conditions: 1 m 29, 0 n 29, and m n.

³ For n, specify the length in bytes as an unsigned integer. The specified value must satisfy the condition 1 n 32767.

⁴ For n, specify the length in characters as an unsigned integer. The specified value must satisfy the condition 1 n 16383.

⁵ The specified length serves the same purpose as the XTLOBBUFSIZE environment variable, and the former takes precedence over the latter. The following table shows the permitted value ranges and the actual maximum lengths:

Unit | Range of n | Actual size (bytes)
None | 1 n 2147483647​ | Same as at left
K | 1 n 2097152​ | n x 1024
M | 1 n 2048 | n x 1048576​
G | 1 n 2 | n x 1073741824​

Note that if the calculation result of the actual maximum length is 2147483648, HiRDB Dataextractor uses the value 2147483647.

⁶ If the XTLOBBUFSIZE environment variable is omitted, HiRDB Dataextractor may be unable to allocate the buffer, resulting in error termination.

⁷ If the specified length is greater than the length of the BLOB data type defined at the target system, HiRDB Dataextractor ignores this specification and assumes the defined length.

⁸ For n, specify the length in bytes as an unsigned integer. The specified value must satisfy the condition 1 n 2147483647.

⁹ The value of n must be 0, 2, 4, or 6.

(6) Lock information file

In the lock information file, specify the lock information for data extraction.

The information to be specified in the lock information file is shown below.

When the specified value of the XTSQL environment variable is 0 or when the XTSQL environment variable is omitted
Specify the LOCK statement after LOCK TABLE table-name.

Format

IN EXCLUSIVE MODE NOWAIT

When the specified value of the XTSQL environment variable is 1
Specify the LOCK statement after LOCK TABLE.

Format

table-name IN EXCLUSIVE MODE NOWAIT

Actual LOCK statement that is issued

LOCK TABLE table-name IN EXCLUSIVE MODE NOWAIT

For details about how to specify the LOCK statement, see the manual HiRDB SQL Reference.

Note

Do not specify a semicolon (;) at the end of the specified value.

4.3 Formats of output listings

Organization of this section

(1) Output listing during data extraction

(2) Output listing during data import

(1) Output listing during data extraction

This section explains the format of the listing that is output when HiRDB Dataextractor is executed on the data source system.

The execution results of HiRDB Dataextractor on the data source system are output to the error log file. For details about the name of the error log file, see Table 2-3 Directories and files created by HiRDB Dataextractor. Figure 4-2 shows the structure of the listing that is output during execution of HiRDB Dataextractor on the data source system. Figure 4-3 shows an example of a HiRDB Dataextractor execution results listing on the data source system.

Figure 4-2 Structure of output listing during data extraction

Figure 4-3 HiRDB Dataextractor execution results listing on the data source system

Explanation

The numbers below correspond to the circled numbers in the figure.

Name of program product

Load module name

Version number

Revision number

Date on which PXTCNTL (HiRDB Dataextractor's entry program) was executed (in the format yy-mm-dd)

PXTCNTL execution time (in the format hh:mm:ss)

ID of the process that issued the message

Message output time

HiRDB Dataextractor message

(2) Output listing during data import

This section explains the format of the listing that is output when HiRDB Dataextractor is executed on the data target system.

Figure 4-4 shows the structure of the listing that is output during execution of HiRDB Dataextractor on the data target system. Figure 4-5 shows an example of a HiRDB Dataextractor execution results listing on the data target system.

Figure 4-4 Structure of output listing during data import

1, 2: These represent the execution results of HiRDB Dataextractor's control process and input file creation process on the data target system. These results are output to separate error log files. For details about the names of the error log files, see Table 2-3 Directories and files created by HiRDB Dataextractor.

An output listing contains the ID of HiRDB Dataextractor's data extraction process on the data source system. You can use this process ID to search for the corresponding HiRDB Dataextractor output listing on the target system.

The 1. execution results contain execution results messages from pdload; for details, see the HiRDB Messages manual.

Figure 4-5 HiRDB Dataextractor execution results listing on the data target system

Explanation

The numbers below correspond to the circled numbers in the figure.

Name of program product

Load module name

Version number

Revision number

PXTCNTL execution date (in the format yy-mm-dd)

PXTCNTL execution time (in the format hh:mm:ss)

ID of HiRDB Dataextractor's data extraction process on the data source system
This information is not output if an error occurs during connection establishment.

HiRDB Dataextractor's process type:
M: Control process
F: Input file creation process

ID of the process that issued the message

Message output time

pdload message

HiRDB Dataextractor message

4.4 Examples

This section presents execution examples of HiRDB Dataextractor. Figure 4-6 shows the system configuration for the execution examples.

Figure 4-6 System configuration for execution examples

Organization of this section

(1) Environment for execution examples

(2) Execution examples

(1) Environment for execution examples

(a) Environment on the data source system (HOST1)

Table definition

Definition of the table with authorization identifier user01

CREATE TABLE T01(C01 CHAR(10),C02 CHAR(40),C03 INT)
CREATE TABLE T02(C01 CHAR(10),C02 CHAR(40),C03 INT,C04 INT)
CREATE FIX TABLE T03(C01 CHAR(10), C02 CHAR(40),C03 INT)
CREATE TABLE T04
(C01 INT,
 C02 MVARCHAR(32),
 C03 SGMLTEXT ALLOCATE (SGMLTEXT IN RDLOB01)
  PLUGIN '<TEXTTYPE>SGML</TEXTTYPE><DTD>DOCUMENT DEFINITIONS</DTD>',
 C04 DATE)
CREATE INDEX TEXT_IDX USING TYPE NGRAM
 ON T04(C03) IN RDLOB02

Specification of environment variables

$PDDIR       /HiRDB1
$PDCONFPATH  /HiRDB1/conf
$PDUSER      "user01"/"user01"
$PDNAMEPORT  20000
$SHLIB_PATH  /HiRDB1/lib: /HiRDB1/client/lib
$PATH        /opt/HIRDBXT/bin
$LANG        ja_JP.SJIS
$XTHOST      HOST2
$XTPORTNO    20052

Specification in /etc/hosts at the importing host

       :
       :
160.16.150.120  HOST2
160.16.150.121  HOST3
       :
       :

(b) Environment on the data target system (HOST2)

Definition of the table with authorization identifier user01

CREATE TABLE T01(C01 CHAR(10),C02 CHAR(40),C03 INT)
CREATE TABLE T02(C01 CHAR(10),C02 CHAR(40),C03 INT,C04 INT)
CREATE TABLE T04
(C01 INT,
 C02 MVARCHAR(32),
 C03 SGMLTEXT ALLOCATE (SGMLTEXT IN RDLOB01)
  PLUGIN '<TEXTTYPE>SGML</TEXTTYPE><DTD>DOCUMENT DEFINITIONS</DTD>',
 C04 DATE)
CREATE INDEX TEXT_IDX USING TYPE NGRAM
 ON T04(C03) IN RDLOB02

Definition of the table with authorization identifier user02

CREATE FIX TABLE T03(C01 CHAR(10),C02 CHAR(40),C03 INT)

Definition of port in /etc/services

                     :
                     :
hirdbxt1 20052/tcp    # HiRDB Dataextractor
hirdbxt2 50000/tcp    # HiRDB Dataextractor
                     :
                     :

Definition for HiRDB Dataextractor startup in /etc/inetd.conf

                     :
                     :
hirdbxt1 stream tcp nowait user01
/opt/HIRDBXT/bin/pxtcntl pxtcntl /usr/home/user01/xtenv1
hirdbxt2 stream tcp nowait user02
/opt/HIRDBXT/bin/pxtcntl pxtcntl /usr/home/user02/xtenv2
                     :
                     :

Specification of environment variables in the environment variable information specification file

Environment variable information specification file for service name hirdbxt1 and port number 20052 (/usr/home/user01/xtenv1)

set PDDIR=/HiRDB2
set PDCONFPATH=/HiRDB2/conf
set PDUSER="user01"/"user01"
set LANG=ja_JP.SJIS

Environment variable information specification file for service name hirdbxt2 and port number 50000 (/usr/home/user02/xtenv2)

set PDDIR=/HiRDB2
set PDCONFPATH=/HiRDB2/conf
set PDUSER="user02"/"user02"
set LANG=ja_JP.SJIS

(c) Environment on the file creation system (HOST3)

Definition of port in /etc/services

                    :
                    :
hirdbxt 20052/tcp    # HiRDB Dataextractor
                    :
                    :

Definition for HiRDB Dataextractor startup in /etc/inetd.conf

                    :
                    :
hirdbxt stream tcp nowait user01
/opt/HIRDBXT/bin/pxtcntl pxtcntl /usr/home/user01/xtenv
                    :
                    :

Specification of environment variables in the environment variable information specification file

Environment variable information specification file for service name hirdbxt and port number 20052 (/usr/home/user01/xtenv)

set XTTMPDIR=/usr/home/user01/data
set LANG=ja_JP.SJIS

(2) Execution examples

Specify the xtrep command on the data source system.

(a) Example 1

Copy table user01.T01 into table T01 at HOST2. Specify the following options:

Port number used by HiRDB Dataextractor on the target system is 20052.

Add the data without deleting any existing data.

Acquire a pre-update log.

Number of batch output pages is 10.

Output progress message every 10,000 lines.

Lock the table subject to extraction.

Do not change the default null value.

Command specification

xtrep T01

(b) Example 2

Copy table user01.T01 into table T02 at HOST2. Specify the following options:

Port number used by HiRDB Dataextractor on the target system is 20052.

Delete all existing data and then add the new data.

Do not acquire a log.

Number of batch output pages is 255.

Output progress message every 100,000 lines.

Do not lock the table subject to extraction.

Extract rows with the value '0000010000' in column C01 and set the literal 0 in column C04.

Set the default null value for column C01 to 'FFFFFFFFFF'.

Command specification

xtrep -r T02 -d -l n -n 255 -m 100 -g -s /usr/home/user01/clm
-v /usr/home/user01/null -w /usr/home/user01/whr T01

Contents of /usr/home/user01/clm

C01,C02,C03,0

Contents of /usr/home/user01/whr

WHERE C01<='0000010000'

Contents of /usr/home/user01/null

C01=('FFFFFFFFFF')

(c) Example 3

Copy table user01.T03 into table T03 at HOST2. Specify the following options:

Port number used by HiRDB Dataextractor is 50000.

Delete all existing data.

Acquire a pre-update log.

Number of batch output pages is 40.

Obtain the execution results in /tmp/xtrep_log.

Output progress message every 10,000 lines.

Lock the table subject to extraction.

Use a line-by-line interface for data extraction.

Do not change the default null value.

Command specification

xtrep -d -n 40 -p 50000 -e /tmp/xtrep_log
     -s /usr/home/user01/clm T03

Contents of /usr/home/user01/clm

ROW

(d) Example 4

Copy table user01.T03 to a file at HOST3. Specify the following options:

Create a DAT-format file.

The name of the output file is /usr/home/user01/data/T03.

Command specification

xtrep -R dat -o T03 -h HOST3 T03

(e) Example 5

Copy table user01.T01 to a file at HOST3. Specify the following options:

Create a DAT-format file.

The name of the output file is /usr/home/user01/data/T01.

Output progress message every 50,000 lines.

Extract rows with the value '0000010000' in column C01 and set the literal 0 in the fourth column.

Command specification

xtrep -R dat -o T01 -h HOST3 -m 50 -s /usr/home/user01/clm
-w /usr/home/user01/whr T01

Contents of /usr/home/user01/clm

C01,C02,C03,0

Contents of /usr/home/user01/whr

WHERE C01<='0000010000'

(f) Example 6

Copy table user01.T04 containing SGMLTEXT-type columns into table T04 at HOST2. Create a shell to execute the xtrep command.

Obtain the maximum length of the original text (real data) of the SGMLTEXT type. Specify the obtained value in the XTLOBBUFSIZE environment variable.

Write up to 10 MB into file xt_file1 under /opt/HIRDBXT/spool at HOST2. If file xt_file1 becomes full, write the remaining data into file xt_file2.

Delete all existing data and write the new data.

Example of shell creation

 #!/bin/csh -f
 #-------------------------------------------------------------
 #Obtain max size of SGMLTEXT column

1. echo 'max(length(extracts(C03)))' > xt_clm
2. xtrep -R dat -o size -s xt_clm -h `hostname` T04
 rm -f xt_clm

 #-------------------------------------------------------------
 #Create xtrep parameters and command

3. echo 'C01,C02,extracts(C03),C04' > xt_clm

 echo '#! /bin/csh -f'                              > xt_exec
4. echo 'setenv XTERRLEVEL 1'                        >> xt_exec
 echo 'setenv XTHOST HOST2'                         >> xt_exec
 echo 'setenv XTFILESIZE 10000000'                  >> xt_exec
5. echo 'setenv XTLOBBUFSIZE \c'                     >> xt_exec
 cat  /opt/HIRDBXT/spool/size | cut -c2-11          >> xt_exec
 echo 'xtrep -d -o xt_file1,xt_file2 -s xt_clm T04' >> xt_exec
 chmod 777 xt_exec

 #-------------------------------------------------------------
 #Execute xtrep

6. xt_exec

 rm -f /opt/HIRDBXT/spool/size
 rm -f xt_clm
 rm -f xt_exec

Explanation

Creates column name specification file xt_clm to obtain the maximum length of the real data in the SGMLTEXT-type column (C03) in table user01.T04 that is subject to extraction.

Executes the xtrep command with the xt_clm column name specification file created in 1 above specified, and outputs the maximum length of the real data in the SGMLTEXT-type column (C03) in table user01.T04 to /opt/HIRDBXT/spool/size at HOST1.

Creates column name specification file xt_clm to extract data from table user01.T04.

Outputs the environment variables and command line used by the xtrep command to xt_exec.

Sets the maximum length of the real data output to /opt/HIRDBXT/spool/size in the XTLOBBUFSIZE environment variable.

Executes the xtrep command with the xt_clm column name specification file created in 3 above specified, and imports table user01.T04 into table T04.

5. Extracting Data from ORACLE and Importing It into HiRDB

This chapter explains the procedures for extracting data from an ORACLE database and importing it into a HiRDB table or specifying information for file creation.

Organization of this chapter

5.1 Command

5.2 Formats of output listings

5.3 Examples

5.1 Command

You use the xtrepO command provided by HiRDB Dataextractor to extract data from an ORACLE database and import it into a HiRDB database or save it as a file.

Organization of this section

5.1.1 Command format

5.1.2 xtrepO command

5.1.3 Additional data extraction and import functions

5.1.4 Contents of files specified with the xtrepO command

5.1.1 Command format

This section describes the command format, which is shown below:

Format

command-name options command-argument

Organization of this subsection

(1) command-name

(2) options

(3) command-argument

(1) command-name

The command name is the filename of the command that is to be executed.

To execute a command, you must specify appropriate environment variables in your environment settings. For details about how to specify the environment variables that are required for execution of the xtrepO command, see 2.2.3 Specifying environment variables.

(2) options

An option specifies one of the following types of information:

A qualification of the command's action

A qualification of the object of the action

The following explains how to specify options. In the examples, the dollar sign ($) indicates a shell prompt and cmd indicates the command name.

An option is a character string beginning with a hyphen (-). It can be followed by flag arguments (or by no flag arguments). The following is the format of an option:

-option-flag

or

-option-flag flag-arguments

option-flag: One alphanumeric character (which is case sensitive)
flag-arguments: Arguments of the option flag (when you specify multiple flag arguments, you separate them with the comma (,))

If an option flag has a required flag argument, you cannot omit that flag argument.

If a flag argument contains a space, you must enclose the entire flag argument in double quotation marks (") in order to enter the command from the shell.

Example

Option f with arguments 1 and 2 is specified as follows:

$ cmd -f "1 2"

You cannot specify the same option flag more than once.

Specify all options before any command arguments.

(3) command-argument

The command argument specifies the direct object of the command's action.

5.1.2 xtrepO command

Organization of this subsection

(1) Function

(2) Executor

(3) Executing server machine

(4) Format

(5) Options

(6) Combination of xtrepO command options

(1) Function

The xtrepO command extracts data from a specified table and imports it into a target table on the target system. It can also create a file after data extraction, depending on an operand specification.

(2) Executor

The executor must be registered as an ORACLE user. There are also some limitations applicable to a user who is specified in the XTORAUSER environment variable. For details, see (2) in 2.2.3 Specifying environment variables.

Additionally, there are some restrictions on the user who can start HiRDB Dataextractor on the target system. For details, see 2.2.4(3) Specifying /etc/inetd.conf or 6.2.2 Starting and terminating HiRDB Dataextractor when using OSI.

(3) Executing server machine

Execute the xtrepO command at the ORACLE server machine that is to be subject to data extraction.

(4) Format

xtrepO [-r [schema-name.][table-identifier]
     [-R [{bin|dat}][,separator-character]]
     [-o [{output-filename|output-directory-name}
          [,{output-filename|output-directory-name}]]]
     [-O [{output-filename|output-directory-name}
          [,{output-filename|output-directory-name}]]]
     [-y]
     [-j RDAREA-name]
     [-h target-host-name]
     [-H single-server's-host-name-or-system-manager's-host-name
       [,front-end-server's-host-name-or-back-end-server's-host-name]]
     [-p port-number]
     [-f front-end-server-name-or-back-end-server-name]
     [-d]
     [-i index-creation-mode]
     [-I [pdload-control-information-environment-variable-name]
        [,pdload-command-line-information-environment-variable-name]
        [,pdload-control-information-file's-source-statement-
          information-environment-variable-name]]
     [-l log-acquisition-mode]
     [-L import-information-filename]
     [-n batch-output-pages-count]
     [-z]
     [-e error-log-filename]
     [-m progress-message-output-interval]
     [-g [lock-information-filename]]
     [-s column-name-specification-filename]
     [-w table-expression-specification-filename]
     [-v null-value-information-filename]
     [-b LOB-input-file-storage-directory-name]
     [-q error-data-filename[,output-lines-count]]
     [-x shell-script-filename]
     [schema-name.]table-identifier

(5) Options

For the most part, the options of the xtrepO command are the same as the xtrep command's options. Only those options that are unique to the xtrepO command are explained below. For details about the other options, see (4) in 4.2.2 xtrep command.

-L import-information-filename

~ <pathname> ((1-255 characters))

Specify the absolute pathname of the import information file. This option is required in the following cases:

The data type of extracted data is to be changed.

The length of extracted data is to be changed.

For details about how to specify the import information file, see 5.1.4 Contents of files specified with the xtrepO command.

-g [lock-information-filename]

~ <pathname> ((1-255 characters))

Specify the lock mode. The following explains the relationship between this option and the lock information file:

When this option is omitted
HiRDB Dataextractor uses the LOCK statement (always LOCK TABLE table-name IN SHARE MODE) for lock control.

When this option is specified
HiRDB Dataextractor does not issue the LOCK statement.

When this option is specified and the lock information file is specified
HiRDB Dataextractor uses the LOCK statement (specified in the lock information file) for lock control. For details about how to specify the lock information file, see 5.1.4 Contents of files specified with the xtrepO command.

(6) Combination of xtrepO command options

The valid xtrepO command options depend on the facility to be used after data extraction. To import extracted data into a table, you must omit the -R option; to only create a file without importing data into a table, you must specify the -R option. Table 5-1 shows the combinations of xtrepO command options.

Table 5-1 Combination of xtrepO command options

Option
Facility to be used

Format
Specified information
Import facility
File creation facility

-r
Name of table to be subject to data import
O
N

-R
File creation
I
F

-o
Output filename or directory name (when not deleted)
O
R

-O
Output filename or directory name (when deleted)
O
N

-y
Whether or not to overwrite file
O
O

-j
Name of RDAREA to be subject to data storage
O
N

-h
Name of host to be subject to processing
O
O

-H
Name of host to be subject to data import (when the hosts on source and target systems use different LANs)
O
N

-p
Port number subject to processing
O
O

-f
FES or BES at the destination
O
N

-d
Storage method (value specified with pdload)
O
N

-i
Index creation method (value specified with pdload)
O
N

-I
Name of pdload control information environment variable
Name of pdload command line information environment variable
Name of pdload control information file's source statement information environment variable
O
N

-l
Log acquisition mode (value specified with pdload)
O
N

-L
Import information filename
O
O

-n
Number of batch output pages (value specified with pdload)
O
N

-z
0-byte characters storage (value specified with pdload)
O
N

-e
Name of error log file
O
O

-m
Progress message output interval
O
O

-g
Lock mode
O
O

-s
Name of column name specification file
O
O

-w
Name of table expression specification file
O
O

-v
Name of null value information file
O
O

-b
Name of LOB input file storage directory
O
O

-q
Name of error data file and number of output lines
O
N

-x
Name of shell script file
N
O

*
Name of table to be subject to data extraction
R
R

F: Option that specifies the facility that is to be used.

I: Must not be specified when data is to be imported into a table. When the -R option is specified, HiRDB Dataextractor executes the file creation facility and does not import data into a table.

R: Required option (if omitted, HiRDB Dataextractor outputs the JXU7300E message, resulting in an error).

O: Optional option.

N: Option that cannot be specified (if specified, HiRDB Dataextractor outputs the JXU7306E or JXU7307E message, resulting in an error).

* Specify [authorization-identifier.]table-identifier.

5.1.3 Additional data extraction and import functions

Of the functions used during data extraction from an ORACLE database and during data import into a HiRDB table, this subsection describes the following functions:

SQL user specification function during data extraction

Loader parameter specification function

Character codes conversion function

Organization of this subsection

(1) SQL user specification function during data extraction

(2) Loader parameter specification function

(3) Character code conversion function

(1) SQL user specification function during data extraction

HiRDB Dataextractor enables the user to specify desired information in the following SQL statements that are issued when data is extracted from an ORACLE database.

LOCK TABLE statement

SELECT statement

Table 5-2 explains the scope of this function.

Table 5-2 Scope of the SQL user specification function during ORACLE data extraction

Data linkage type | Source | Target | Applicability
XDM/XT linkage | XDM/RD | HiRDB | --
Sequential dataset | --
ORACLE | XDM/RD | Y
Sequential dataset | Y
HiRDB Dataextractor linkage | ORACLE | HiRDB | Y
Binary-format file | Y
DAT-format file | Y

Y: Applicable

--: Not applicable to HiRDB Dataextractor

(a) Use with XDM/XT linkage

To use this function when data is extracted from an ORACLE database with XDM/XT linkage, the following specifications are required:

XDM/XT's JXUMCTL control statement
RDBDEF and EXTRACT statements

HiRDB Dataextractor's environment variable information setup file (source system)

The following table lists the environment variables that must be specified in the environment variable information setup file:

Environment variable | Specification
PDHOST | As required*
PDNAMEPORT | As required*
XTEXTRACTDB | Mandatory
XTLCKxxxx | As required
XTTBLxxxx | As required
XTCLMxxxx | As required
XTWHExxxx | As required

Mandatory: Specification is mandatory.

As required: Specify as appropriate.

* This environment variable is required when the RDBDEF statement is specified in XDM/XT's JXUMCTL control statement.

For details about the environment variables, see 2.2.3 Specifying environment variables.

(b) Use with HiRDB Dataextractor linkage

To use this function when data is extracted from an ORACLE database with HiRDB Dataextractor linkage, you execute the xtrepO command.

Environment variable

The XTSQL environment variable must be specified in the source system.

Command options

The following table describes the options whose specification is related to this function:

Command | Option | Value | Import to HiRDB | Binary or DAT file creation
XTSQL | XTSQL
0 | 1 | 0 | 1
xtrepO | -g | -- | O | M | O | M
lock-information-file
-r | [authorization-identifier,]table-identifier | O | M | N | N
-R | -- | N | N | M | M
{bin|dat}
-s | column-name-specification-file-name | O | O | O | O
-w | table-expression-specification-file-name | O | N | O | N
[authorization-identifier,]table-identifier | -- | M | N | M | N
table-expression-specification-file-name | -- | N | M | N | M

M: Mandatory

O: Optional

N: Not specifiable

--: Not specified

-g [lock-information-file-name]
The combination of this option and the XTSQL environment variable is used to perform lock control on the table from which data is extracted. Specification of this option is mandatory when 1 is specified in the XTSQL environment variable.
The following table provides the details of the lock information file specification:

XTSQL | -g option | Action
0 | Omitted | -- | Issue LOCK TABLE using the table name entered on the command line.
Specified | No value specified | Do not issue LOCK TABLE.
Value specified | Issue LOCK TABLE based on information in the lock information file.
1 | Omitted | -- | Error
Specified | No value specified | Do not issue LOCK TABLE.
Value specified | Issue LOCK TABLE based on information in the lock information file.

-r [authorization-identifier,]table-identifier
This option or the -R option must be specified when 1 is specified in the XTSQL environment variable.

-R [{bin|dat}]
This option or the -r option must be specified when 1 is specified in the XTSQL environment variable.

-s column-name-specification-file-name
If necessary, specify the absolute path of the column name specification file.

-w table-expression-specification-file-name
This option cannot be specified when 1 is specified in the XTSQL environment variable.

[authorization-identifier,]table-identifier
Specify this option when the XTSQL environment variable is omitted or 0 is specified in the XTSQL environment variable.

table-expression-specification-file-name
Specify this option when 1 is specified in the XTSQL environment variable.

For details about these options, see 5.1.2 xtrepO command.

File specification method

This subsection describes the specification of files in options.

Lock information file
This file specifies the lock options in the LOCK TABLE statement.
Specify the file contents as follows, as appropriate to the specification of XTSQL:

XTSQL | Specification
0 | Specify the lock options that follow LOCK TABLE table-name.
1 | Specify the lock options that follow LOCK TABLE.

Table expression specification file
This file specifies the table expression in the SELECT statement.
Specify the file contents as follows, as appropriate to the specification of XTSQL:

XTSQL | Specification
0 | Specify the table expression that follows FROM table-name in the SELECT statement.
1 | Specify the table expression that follows FROM in the SELECT statement.

Note

When 1 is specified in the XTSQL environment variable, no column name can be specified in the null value information file. If you specify information such as a default null value or data format of repetition columns, specify applicable field numbers. Specifying column names results in an error.

(2) Loader parameter specification function

When data is imported into a HiRDB table, HiRDB Dataextractor starts HiRDB's database load utility (pdload). The loader parameter specification function enables you to specify desired parameters for pdload.

Table 5-3 explains the scope of this function.

Table 5-3 Scope of loader parameter specification function (when ORACLE data is extracted)

Data linkage type | Source | Target | Applicability
HiRDB Dataextractor linkage | ORACLE | HiRDB | Y

Y: Applicable

(a) Use

To use this function when data is extracted from an ORACLE database, execute the xtrepO command.

Environment variables

At the source system, specify the following environment variables as necessary:

XTLPRMxxxx

XTPDSRxxxx

Command options

The following table describes the options whose specification is related to this function:

Command | Option | Value | Requirement
xtrepO | -d | -- | 1'
-f | server-name | O
-i | {c|s|n|x} | 1'
-I | XTPDCFxxxx | O
XTLPRMxxxx | M, 1
XTPDSRxxxx | M, 2
-j | RDAREA-name | O
-l | {a|p|n} | 1'
-n | buffer-sectors-count | 1'
-q | error-data-file-name,count | 2'
-v | null-value-information-file | O
-z | -- | 1'

M: One of these items is required in order to use this function.

O: This item is optional.

1, 1': These items are mutually exclusive

2, 2': These items are mutually exclusive

-I [XTPDCFxxxx][,XTLPRMxxxx][,XTPDSRxxxx]
Specify at least one value. You can specify multiple values in any order by using the comma (,) as the delimiter.

XTPDCFxxxx (name of pdload control information environment variable)

Specify this information as necessary. For details about the environment variables, see 2.2.3 Specifying environment variables.

XTLPRMxxxx (name of pdload command line information environment variable)

To use this function, ensure that either the XTLPRMxxxx or the XTPDSRxxxx environment variable is specified.

Notes

When you specify this environment variable, none of the following options can be specified:
-d option
-i option
-l option
-n option
-z option

When the name of this environment variable is specified, HiRDB Dataextractor does not specify any parameter other than the table name, control information file name, -b, -k, or -v option when pdload starts; therefore, specify all necessary options in the pdload command line information file.

XTPDSRxxxx (name of pdload control information file's source statement information environment variable)

To use this function, ensure that either the XTLPRMxxxx or the XTPDSRxxxx environment variable is specified.

Note

When you specify this environment variable, do not specify the -q option, as it cannot be specified.

(3) Character code conversion function

This function converts the character codes of the data extracted from the ORACLE database according to specified environment variables and then imports the data.

Table 5-4 explains the scope of this function.

Table 5-4 Scope of the character code conversion function (when ORACLE data is extracted)

Data linkage type | Source | Target | Applicability
HiRDB Dataextractor linkage | ORACLE | HiRDB | Y
Binary-format file | Y
DAT-format file | Y

Y: Applicable

(a) Using the character code conversion function

By specifying environment variables and a null value information file, you can convert the character codes during data import processing.

For details about the environment variables, see (3) Character code conversion function in 4.2.3 Additional data extraction and import functions. For details about the null value information file, see (5) Null value information file in 5.1.4 Contents of files specified with the xtrepO command.

For details about converting Gaiji codes, see (3) Character code conversion function in 4.2.3 Additional data extraction and import functions.

5.1.4 Contents of files specified with the xtrepO command

Among the files specified with the xtrepO command, this section describes the contents of the following files. For details about other files, see 4.2.4 Contents of files specified with the xtrep command.

Column name specification file

Table expression specification file

Lock information file

Import information file

Null value information file

Organization of this subsection

(1) Column name specification file

(2) Table expression specification file

(3) Lock information file

(4) Import information file

(5) Null value information file

(1) Column name specification file

In the column name specification file, specify information for the SELECT statement about the columns to be extracted. HiRDB Dataextractor combines the values specified in the column name specification file with the SELECT statement in order to extract data from the ORACLE database.

select values-specified-in-column-name-specification-file FROM name-of table-subject-to-
extraction

If you omit the -s option, HiRDB Dataextractor assumes an asterisk (*). For details about how to specify selection expressions with the SELECT statement, see the ORACLE manual.

(2) Table expression specification file

In the table expression specification file, specify conditions for the SELECT statement. HiRDB Dataextractor combines the values specified in the table expression specification file with the SELECT statement to extract data from the ORACLE database.

select values-specified-in-column-name-specification-file FROM name-of-table-subject-
to-extraction values-specified-in-table-expression-specification-file

If you omit the -w option, you cannot specify conditions. For details about how to specify conditions with the SELECT statement, see the ORACLE manual.

Note

Do not specify a semicolon (;) at the end of a value.

(3) Lock information file

In the lock information file, specify the lock information for data extraction.

The information to be specified in the lock information file is shown below.

When the specified value of the XTSQL environment variable is 0 or when the XTSQL environment variable is omitted
Specify the LOCK statement after LOCK TABLE table-name.

Format

IN EXCLUSIVE MODE NOWAIT

When the specified value of the XTSQL environment variable is 1
Specify the LOCK statement after LOCK TABLE.

Format

table-name IN EXCLUSIVE MODE NOWAIT

Actual LOCK statement that is issued:

LOCK TABLE table-name IN EXCLUSIVE MODE NOWAIT

For details about how to specify the LOCK statement, see the ORACLE manual.

Note

Do not specify a semicolon (;) at the end of a value.

(4) Import information file

In the import information file, specify the columns that are to be subject to data type conversion and the applicable data types. You specify an import information file in the following cases:

Extracted data is only to be output to a file.
HiRDB Dataextractor extracts the data with the specified data types. Table 5-5 shows the values that are assumed when the import information file (-L option) is omitted and when no data type is specified for a column.

The following data types are to be extracted as HiRDB BLOB or BINARY type and imported or stored in a file:

LONG

LONG RAW

BLOB

BFILE

CLOB

NCLOB

Specify the maximum data length for each column. This saves buffer space because HiRDB Dataextractor uses only the specified buffer size. If the import information file (-L option) is omitted or if no data type is specified for a column, the buffer size depends on the value set in the XTLOBBUFSIZE environment variable.

Format

FORMAT
 {FIELD_NUM field-number|FIELD_NAME column-name} ATTR data-type
   [[FIELD_NUM field-number|FIELD_NAME} ATTR data-type]...

Description

FORMAT

Indicates that a data type is to be converted.

FIELD_NUM

Specify a column subject to data type conversion, expressed as its sequential number from the first column that is to be subject to extraction.

-s option omitted

Sequence number from the beginning of the definitions of the extraction table

-s option specified

Sequence number from the first column name specified in the column name specification file

You must specify a value in the range 1 to 99999. The same field number cannot be specified more than once.

FIELD_NAME

Specify the name of a column to be extracted that is to be subject to data type conversion. If you have specified the -s option, you cannot specify FIELD_NAME, and must specify FIELD_NUM instead. Do not specify the same column name more than once.

ATTR

Specify the data type. Table 5-6 lists the permitted data types.

Notes

Use one line to specify the information about one column. To specify information about multiple columns, specify as many lines as there are columns.

A comment begins with the number sign (#) and ends at the end of the line.

If a column name contains a space or hyphen (-), enclose the column name in double quotation marks (").

To have a column name handled as being case sensitive, enclose it in double quotation marks ("). If you do not enclose it in double quotation marks, the column name is assumed to be all uppercase letters.

Table 5-5 Default data types

ORACLE data type
Length
Assumed data type

CHAR(n)
VARCHAR2(n)
NCHAR(n)
NVARCHAR2(n)
N/A
MCHAR(x)¹

NUMBER
NUMBER(p)
or
NUMBER(p,0)
p < 5
SINT

p < 10
INT

9 < p < 30
DEC(p)

NUMBER(p,s)
and
s <> 0
p < 30 and 0 < s p
DEC(p,s)

p < s and s < 30
DEC(s,s)

s < 0 and p+|s| < 30
DEC(p+|s|,0)

Other
FLT

DATE
N/A
DATE²

LONG
N/A
BLOB(x)³

LONG RAW
--

RAW
--

BLOB
--

CLOB
--

NCLOB
--

BFILE
--

¹ If the ORACLE data type is NCHAR or NVARCHAR2, x = n x 2; If the ORACLE data type is not NCHAR or NVARCHAR2, x = n.

² Only the date information is retrieved. If the data is a B.C. year, HiRDB Dataextractor terminates with an error.

³ The value of x depends on the value set in the XTLOBBUFSIZE environment variable.

Table 5-6 Data types permitted for ATTR

Permitted data type¹ | Corresponding HiRDB data type | File creation | HiRDB import
INT | INTEGER | Y | --
SINT | SMALLINT | Y | --
DEC(m,n)² | DECIMAL(m,n) | Y | --
FLT | FLOAT | Y | --
SFLT | SMALLFLT | Y | --
CHAR(n)³ | CHAR(n) | Y | --
VARCHAR(n)³ | VARCHAR(n) | Y | --
MCHAR(n)³ | MCHAR(n) | Y | --
MVARCHAR(n)³ | MVARCHAR(n) | Y | --
NCHAR(n)⁴ | NCHAR(n) | Y | --
NVARCHAR(n)⁴ | NVARCHAR(n) | Y | --
DATE | DATE | Y | --
TIME | TIME | Y | --
YEAR | INTERVAL YEAR TO DAY | Y | --
HOUR | INTERVAL HOUR TO SECOND | Y | --
BLOB(n[{K|M|G}])⁵ | BLOB(n[{K|M|G}]) | Y 6 | Y 7
SGMLTEXT(n[{K|M|G}])⁵ | SGMLTEXT | N | N
BINARY(n)⁸ | BINARY(n) | Y⁶ | Y⁷
TIMESTAMP(n)⁹ | TIMESTAMP(n) | Y | --

Y: Can be specified.

--: Cannot be specified (the specification is ignored and the data type of the target system is assumed).

N: Cannot be specified (results in an error if specified).

¹ For the combinations of ORACLE data types and permitted data types, see Tables 3-7 and 3-8.

² The values of m and n must satisfy the conditions 1 m 29, 0 n 29, and m n.

³ For n, specify the length in bytes as an unsigned integer. The permitted value range is 1 n 32767.

⁴ For n, specify the number of characters as an unsigned integer. The permitted value range is 1 n 16383.

⁵ The length of the specified value has the same meaning as the value set in the XTLOBBUFSIZE environment variable and takes precedence over this environment variable. The following shows the value ranges and actual maximum lengths:

Unit | Value range of n | Actual size (bytes)
None | 1 n 2147483647​ | Same as at the left
K | 1 n 2097152​ | n x 1024
M | 1 n 2048 | n x 1048576​
G | 1 n 2 | n x 1073741824​

If the actual maximum length obtained from the calculation is 2147483648, 2147483647 is assumed.

⁶ If you have omitted the XTLOBBUFSIZE environment variable, you must specify this value. If you do not specify this value, HiRDB Dataextractor may terminate with an error because it cannot allocate buffer space.

⁷ If the specified length is greater than the length defined for the BLOB data type on the target system, HiRDB Dataextractor ignores this specification and uses the defined length.

⁸ For n, specify the length in bytes as an unsigned integer. The specified value must satisfy the condition 1 n 2147483647.

⁹ The value of n must be 0, 2, 4, or 6.

(5) Null value information file

Specify the null value information file in the following cases:

The default null value is to be changed.
If you want to store the null value in a column that is subject to data import, you can use a null value information file to change the null value. If an extract data item matches the specified value, HiRDB Dataextractor stores the null value in the corresponding table column.
In the case of file creation, specify the default null value to be stored in the file when the extracted data contains a null value.
For details about the null value when the null value information file is omitted (the -v option is omitted) and the default value of the null value that is set by this specification, see Table 4-11.

Format

{column-name|field-number=NUM}
 {[={HIGH|LOW|ZERO|SPACE|('literal')|
        (X'hexadecimal-literal')}]|
   [,{NOCODECONV|CODECONV}]}

Description

column-name

Specify the name of the column whose default null value is to be changed.

Importing data to a HiRDB table
Specify the column name of the table on the target system.

Only creating a file
Specify the name of the column of the table on the source system. When the -s option is specified, you cannot specify this information.

field-number=NUM

Specify the column whose default null value is to be changed, expressed as its sequential number from the beginning. You must specify a value in the range 1 to 99999. You cannot specify the same field number more than once.

Importing data into a HiRDB table
Sequence number from the beginning of the definitions of the import table.

Only creating a file
-s option omitted
Sequence number from the beginning of the definitions of the extraction table.
-s option specified
Sequence number from the first column name specified in the column name specification file.

{HIGH|LOW|ZERO|SPACE|('literal')|(X'hexadecimal-literal')}

Specify the default null value.

For details about the value that is set by this specification, see Table 4-11.

{NOCODECONV|CODECONV}

For each column, specify whether or not the codes are to be converted.

NOCODECONV: Specify this value when you are not using the character code conversion function. This value is effective only when the XTLOCALE environment variable is specified for codes to be converted.

CODECONV: Specify this value when you are using the character code conversion function. This value is effective only when the XTLOCALE environment variable is specified for codes to be converted.

Rules

Use one line to specify information for one column. To specify information about multiple columns, specify as many lines as there are columns.

A comment begins with the number sign (#) and ends at the end of the line.

If a column name contains a space or hyphen (-), enclose the column name in double quotation marks (").

To have a column name handled as being case sensitive, enclose it in double quotation marks (").

A column name that is not enclosed in double quotation marks (") is assumed to be all uppercase letters.

When you specify a literal, check that its length does not exceed 255 bytes.

Do not specify ') (a single quotation mark immediately followed by a closing parenthesis) in the literal.

In the case of data import into a HiRDB table, if the target column has the non-NULL attribute, the default null value is stored as is as the data.

If the column on the source system has the non-NULL attribute during file creation, HiRDB Dataextractor ignores this option.

Example

CLM01=HIGH                        #INT
CLM02=LOW                         #DATE
CLM03=('FFFF')                    #CHAR(4)
4=NUM=SPACE                       #CHAR(4)

The specification rules for the null value information file differ depending on the specification in the XTNLDFLT environment variable. Table 5-7 describes these specification rules.

Table 5-7 Null-value information file specification rules (applicable to data extraction from an ORACLE database)

Specification in the null value information file
XTNLDFLT environment variable

0 or 1
2

Import to HiRDB
File creation
Import to HiRDB
File creation

Binary format
DAT format
Binary format
DAT format

column-name|
field-number=NUM
M
M
M
M
M
M

=default-null-value
Y
Y
Y
N
N
N

NOCODECONV|CODECONV
Y
Y
Y
Y
Y
Y

M: Mandatory

Y: Can be specified

N: Cannot be specified

5.2 Formats of output listings

For the formats of output listings, see 4.3 Formats of output listings.

5.3 Examples

This section presents execution examples of HiRDB Dataextractor. Figure 5-1 shows the system configuration for the execution examples.

Figure 5-1 System configuration for execution examples (when data is extracted from an ORACLE database)

Organization of this section

(1) Environment for execution examples

(2) Execution examples

(1) Environment for execution examples

(a) Environment on the data source system (HOST1)

Table definition

Table name | Column names and attributes
TORA01 | C01 CHAR(10), C02 NUMBER(10,8), C03 DATE
TORA02 | C01 CHAR(10), C02 NUMBER(10,8), C03 NUMBER

Specification of environment variables

$ORACLE_BASE /ORACLE8/ORACLE
$ORACLE_HOME /ORACLE8/ORACLE/product/8.1.6
$ORA_NLS33   /ORACLE8/ORACLE/product/8.1.6/ocommon/nls/admin/data
$NLS_LANG    Japanese_Japan.JA16SJIS
$ORACLE_SID  hds1
$ORACLE_TERM hp
$XTORAUSER   "user01"/"user01"
$PATH        /opt/HIRDBXT/bin
$LANG        ja_JP.SJIS
$XTHOST      HOST2
$XTPORTNO    20052

Specification in /etc/hosts at the importing host

       :
       :
160.16.150.120  HOST2
160.16.150.121  HOST3
       :
       :

(b) Environment on the data target system (HOST2)

Table definition

Definition of the table with authorization identifier user01

CREATE TABLE T01(C01 CHAR(10),C02 DEC(10,8),C03 DATE,C04 TIME)
CREATE TABLE T02(C01 CHAR(10),C02 DEC(10,8),C03 INT, C04 INT)

Definition of the table with authorization identifier user02

CREATE FIX TABLE T03(C01 CHAR(10),C02 DEC(10,8),C03 TIME)

Definition of port in /etc/services

                     :
                     :
hirdbxt1 20052/tcp    # HiRDB Dataextractor
hirdbxt2 50000/tcp    # HiRDB Dataextractor
                     :
                     :

Definition for HiRDB Dataextractor startup in /etc/inetd.conf

                     :
                     :
hirdbxt1 stream tcp nowait user01
/opt/HIRDBXT/bin/pxtcntl pxtcntl /usr/home/user01/xtenv1
hirdbxt2 stream tcp nowait user02
/opt/HIRDBXT/bin/pxtcntl pxtcntl /usr/home/user02/xtenv2
                     :
                     :

Specification of environment variables in the environment variable information specification file

Environment variable information specification file for service name hirdbxt1 and port number 20052 (/usr/home/user01/xtenv1)

set PDDIR=/HiRDB2
set PDCONFPATH=/HiRDB2/conf
set PDUSER="user01"/"user01"
set LANG=ja_JP.SJIS

Environment variable information specification file for service name hirdbxt2 and port number 50000 (/usr/home/user02/xtenv2)

set PDDIR=/HiRDB2
set PDCONFPATH=/HiRDB2/conf
set PDUSER="user02"/"user02"
set LANG=ja_JP.SJIS

(c) Environment on the file creation system (HOST3)

Definition of port in /etc/services

                    :
                    :
hirdbxt 20052/tcp    # HiRDB Dataextractor
                    :
                    :

Definition for HiRDB Dataextractor startup in /etc/inetd.conf

                    :
                    :
hirdbxt stream tcp nowait user01
/opt/HIRDBXT/bin/pxtcntl pxtcntl /usr/home/user01/xtenv
                    :
                    :

Specification of environment variables in the environment variable information specification file

Environment variable information specification file for service name hirdbxt and port number 20052 (/usr/home/user01/xtenv)

set XTTMPDIR=/usr/home/user01/data
set LANG=ja_JP.SJIS

(2) Execution examples

Specify the xtrepO command on the data source system.

(a) Example 1

Copy table TORA01 at HOST1 into table T01 at HOST2. Specify the following options:

Port number used by the HiRDB Dataextractor on the target system is 20052.

Add the data without deleting any existing data.

Acquire a pre-update log.

Number of batch output pages is 10.

Output progress message every 10,000 lines.

Lock the table subject to extraction.

Do not change the default null value.

Command specification

xtrepO -r T01 -s /usr/home/user01/clm TORA01

Contents of /usr/home/user01/clm

C01,C02,C03,C04

(b) Example 2

Copy table TORA02 at HOST1 into table T02 at HOST2. Specify the following options:

Port number used by the HiRDB Dataextractor on the target system is 20052.

Delete all existing data and then add the new data.

Do not acquire a log.

Number of batch output pages is 255.

Output progress message every 100,000 lines.

Do not lock the table subject to extraction.

Extract rows with the value '0000010000' in column C01 and set the literal 0 in column C04.

Set the default null value for column C01 to 'FFFFFFFFFF'.

Command specification

xtrepO -r T02 -d -l n -n 255 -m 100 -g -s /usr/home/user01/clm
-v /usr/home/user01/null -w /usr/home/user01/whr TORA02

Contents of /usr/home/user01/clm

C01,C02,C03,0

Contents of /usr/home/user01/whr

WHERE C01<='0000010000'

Contents of /usr/home/user01/null

1=NUM=('FFFFFFFFFF')

(c) Example 3

Copy table TORA01 at HOST1 into table T03 at HOST2. Specify the following options:

Port number used by HiRDB Dataextractor is 50000.

Delete all existing data.

Acquire a pre-update log.

Number of batch output pages is 40.

Obtain the execution results in /tmp/xtrep_log.

Output progress message every 10,000 lines.

Lock the table subject to extraction.

Do not change the default null value.

Command specification

xtrepO -d -r t03 -n 40 -p 50000
      -e /tmp/xtrep_log -g /usr/home/user01/lck TORA01

Contents of /usr/home/user01/lck

IN EXCLUSIVE MODE NOWAIT

(d) Example 4

Output table TORA01 at HOST1 to a file at HOST3. Specify the following options:

Create a DAT-format file.

The name of the output file is /usr/home/user01/data/TORA01.

Do not specify a data type to be converted for any column.

Command specification

xtrepO -R dat -o TORA01 -h HOST3 -s /usr/home/user01/clm TORA01

Contents of /usr/home/user01/clm

C01,C02,C03

(e) Example 5

Output table TORA01 at HOST1 to a file at HOST3. Specify the following options:

Create a binary-format file.

The name of the output file is /usr/home/user01/data/TORA01_BIN.

Convert column C01 in the extraction table to the MCHAR(20) attribute.

Convert column C03 in the extraction table to the TIME attribute.

Output progress message every 50,000 lines.

Extract rows with the value '0000010000' in column C01.

Command specification

xtrepO -R -o TORA01_BIN -h HOST3 -m 50
-s /usr/home/user01/clm -w /usr/home/user01/whr -L
/usr/home/user01/cnv TORA01

Contents of /usr/home/user01/clm

C01,C02,C03

Contents of /usr/home/user01/whr

WHERE C01<='0000010000'

Contents of /usr/home/user01/cnv

FORMAT FIELD_NUM 1 ATTR MCHAR(20)
      FIELD_NUM 3 ATTR TIME

6. Operation

This chapter explains the procedures for starting and terminating HiRDB Dataextractor.

Organization of this chapter

6.1 Operating procedure

6.2 Starting and terminating HiRDB Dataextractor

6.1 Operating procedure

This section explains the HiRDB Dataextractor operating procedure.

Organization of this section

(1) Data extraction and import between HiRDBs

(2) Importing data extracted from ORACLE to HiRDB

(3) Data extraction and import between mainframe database and HiRDB or ORACLE

(4) Creating a file with extracted data

(5) Notes

(1) Data extraction and import between HiRDBs

To extract data from a HiRDB and then import it into another HiRDB, you specify the data extraction and import procedures in HiRDB Dataextractor's xtrep command on the source system.

When the xtrep command is executed on the source system, HiRDB Dataextractor starts in order to execute extraction processing, extracts data, and then sends it to the target system. When data is received on the target system, HiRDB Dataextractor starts automatically and executes import processing.

(2) Importing data extracted from ORACLE to HiRDB

To extract data from an ORACLE database and then import it into a HiRDB, you specify the data extraction and import procedures in HiRDB Dataextractor's xtrepO command on the source system.

When the xtrepO command is executed on the source system, HiRDB Dataextractor starts in order to execute extraction processing, extracts data, and then sends it to the target system. When data is received on the target system, HiRDB Dataextractor starts automatically and executes import processing.

(3) Data extraction and import between mainframe database and HiRDB or ORACLE

To extract data from a mainframe database and then import it into a HiRDB or to extract data from a HiRDB or ORACLE database and then import it into XDM/RD, you specify the data extraction and import procedures in XDM/XT on the VOS3 system.

In the case of data extraction from a mainframe database followed by data import into HiRDB, when the target system receives the data from XDM/XT, HiRDB Dataextractor starts according to specified information and executes import processing.

In the case of data extraction from a HiRDB or ORACLE database followed by data import into XDM/RD, HiRDB Dataextractor is started by XDM/XT on the source system according to specified information, it executes extraction processing, and then it sends the data to XDM/XT. XDM/XT outputs the received data to an extraction dataset so that data from this dataset can be imported into XDM/RD.

(4) Creating a file with extracted data

To create a file with data extracted from a HiRDB or ORACLE database, you specify the data extraction and file creation procedures in HiRDB Dataextractor's xtrep or xtrepO command on the source system.

If you execute the xtrep or xtrepO command on the source system, HiRDB Dataextractor starts in order to execute extraction processing and sends the extracted data to the file creation system. When the file creation system receives the data, it starts HiRDB Dataextractor automatically, and then HiRDB Dataextractor starts file creation processing.

To extract data from a mainframe database and then create a file, you specify the database extraction and file creation procedures in XDM/XT on the VOS3 system.

When the system on the file creation system receives data from XDM/XT, HiRDB Dataextractor starts according to the specified information and executes file creation processing.

(5) Notes

The directories listed below contain the files that are created dynamically by HiRDB Dataextractor during operation. You should delete these files periodically while HiRDB Dataextractor is stopped.

/opt/HIRDBXT/spool/

/opt/HIRDBXT/dump/

6.2 Starting and terminating HiRDB Dataextractor

The HiRDB Dataextractor startup and termination procedures depend on the protocol being used. This section explains the procedures for both protocols.

Organization of this section

6.2.1 Starting and terminating HiRDB Dataextractor when using TCP/IP

6.2.2 Starting and terminating HiRDB Dataextractor when using OSI

6.2.1 Starting and terminating HiRDB Dataextractor when using TCP/IP

When TCP/IP is used, the HiRDB Dataextractor startup and termination procedures depend on whether HiRDB Dataextractor is on the data source system or the data import/file creation system.

Organization of this subsection

(1) Starting and terminating HiRDB Dataextractor on the data source system

(2) Starting and terminating HiRDB Dataextractor on the data import/file creation system

(1) Starting and terminating HiRDB Dataextractor on the data source system

In the case of data extraction from a HiRDB or ORACLE database, the HiRDB Dataextractor on the source system is started by the xtrep or xtrepO command and terminates when import or file creation processing is completed.

In the case of data extraction from a HiRDB or ORACLE database and import into XDM/RD or creation of a sequential dataset, the HiRDB Dataextractor on the source system is started by XDM/XT using the inetd OS command according to information specified in /etc/inetd.conf. HiRDB Dataextractor terminates when the import or sequential dataset creation processing is completed.

(2) Starting and terminating HiRDB Dataextractor on the data import/file creation system

The HiRDB Dataextractor on the data target/file creation system is started by the inetd OS command according to information specified in /etc/inetd.conf when extracted data is sent from a source system. When the processing is completed, HiRDB Dataextractor terminates automatically.

For details about the /etc/inetd.conf specification, see 2.2.4 Files required in order to use HiRDB Dataextractor.

6.2.2 Starting and terminating HiRDB Dataextractor when using OSI

This section explains the HiRDB Dataextractor startup and termination procedures when the OSI protocol is used to execute data extraction, data import, and file creation with a mainframe database.

When the OSI protocol is used, the host used to start HiRDB Dataextractor depends on the HiRDB Dataextractor facility being used. Table 6-1 shows the host used to start HiRDB Dataextractor when the OSI protocol is used.

HiRDB Dataextractor is started by the startup user. You should note the following:

If you intend to extract data and create a file and the file to be created (including a LOB input file) already exists, you must have the write privilege. You can specify the file mode for the created file with the XTFPERMIT or XTDPERMIT environment variable. For details about how to specify these environment variables, see (2) in 2.2.3 Specifying environment variables.

To extract data from an ORACLE database, you must be a registered ORACLE user.

Table 6-1 Host used to start HiRDB Dataextractor when OSI protocol is used

Type of HiRDB Dataextractor
Source system
Target system
File creation system

Host used for startup
For a HiRDB/Single Server:

Host at which the single server is located

For a HiRDB/Parallel Server, one of the following servers that is connected with the OSI protocol:

System manager

Front-end server

Back-end server

Dictionary server

For a HiRDB/Single Server:

Host at which the single server is located

For a HiRDB/Parallel Server:

Host containing the server that is connected with the OSI protocol and to which data is sent (front-end server or back-end server)

Host containing the system manager*

Host used to create the file(s) and which is connected with the OSI protocol

* If the system manager is not connected with XDM/XT by the OSI protocol, the TCP/IP protocol is used to establish communication between the system manager and the target server to which data is sent. For this reason, to start and terminate the HiRDB Dataextractor running on the system manager, use the procedures described in 6.2.1 Starting and terminating HiRDB Dataextractor when using TCP/IP.

Organization of this subsection

(1) Starting HiRDB Dataextractor when using OSI

(2) Terminating HiRDB Dataextractor when using OSI

(1) Starting HiRDB Dataextractor when using OSI

When the OSI protocol is being used, you can start HiRDB Dataextractor either automatically or manually.

(a) Automatic startup

To start HiRDB Dataextractor automatically, you must register to /sbin/rc a script for starting the shell that executes the xtstart command.

Environment setup procedure for automatic startup

Creating the execution shell for the xtstart command
Create the execution shell for the xtstart command in any directory.

Creating the startup script to be started from rc
In /sbin/init.d, create the startup script for shell execution that was created in 1.

Registering the startup script
Register the startup script to sequencer-directory/sbin/rc*.d (* (execution level): 0-n) according to the execution level and the naming conventions. The sequencer directory must consist of a symbolic link to the startup script found in /sbin/init.d.
For naming conventions of the file to be specified, see the rc reference.

Example

ln -s /sbin/init.d/XTS /sbin/rc2.d/S600XTS

Note: The underlined sections must be the same.

Note

Because a 3-digit number is used for sequencing the script in the sequencer directory, set the number so that it is executed after XNF is started. For details about the execution level, see the manual of the OS being used.

Example of creating the xtstart command execution shell

#!/sbin/sh
#
# HiRDB Dataextractor Start
#
export XTTEMPNAM=0
/opt/HIRDBXT/bin/xtstart /HIRDBXT/user01/xtenv1 /HIRDBXT/user01/xtosi1

Example of creating /sbin/init.d/XTS (when the path name of the xtstart command execution shell is /HIRDBXT/user01/xts)

#!/sbin/sh
#
# HiRDB Dataextractor Start script
#

PATH=/usr/sbin:/usr/bin:/sbin
export PATH

rval=0

case $1 in
'start_msg')
 echo "Starting HiRDB Dataextractor"
 ;;

'stop_msg')
 echo "Stopping HiRDB Dataextractor"
 ;;

'start')
 for start_file in ls /HIRDBXT/user01/xts  ; do
   if [ -x ${start_file} ]  ; then
     ${start_file}
     if [ $? !=0 ]  ; then
       rval=1
       break
     fi
   fi
 done
 ;;
'stop')
 ;;

*)
 echo "usge: $0 {start|stop|start_msg|stop_msg}"
 rval=1
 ;;
esac

exit $rval

(b) Manual startup

You can start HiRDB Dataextractor manually in the following cases:

Automatic startup information for HiRDB Dataextractor is not specified in /etc/localrc.

HiRDB Dataextractor was terminated with kill(1), and it is to be restarted without first shutting down the power.

HiRDB Dataextractor has terminated abnormally, and it is to be restarted.

Specification format

/opt/HIRDBXT/bin/xtstart environment-variable-information-setup-filename communication-configuration-definition-information-filename

(c) Notes

HiRDB Dataextractor must be active before XDM/XT is started.

To start HiRDB Dataextractor automatically, set up the system so that XNF starts before HiRDB Dataextractor automatic startup is performed.

To start HiRDB Dataextractor manually, have the superuser execute the xtstart command. If some other user starts HiRDB Dataextractor, a core dump cannot be output in the event of a HiRDB Dataextractor error. Also, be sure that XNF has started before starting HiRDB Dataextractor.

(2) Terminating HiRDB Dataextractor when using OSI

HiRDB Dataextractor terminates processing when it receives the SIGTERM signal.

To terminate only HiRDB Dataextractor:

Obtain HiRDB Dataextractor's process ID from a message output to the log file.

Use kill(1) to send SIGTERM to HiRDB Dataextractor.

7. Error Handling Procedures

This chapter describes the procedures for handling errors that occur during execution of HiRDB Dataextractor.

Organization of this chapter

7.1 HiRDB Dataextractor error handling procedures

7.1 HiRDB Dataextractor error handling procedures

This section describes the procedures for handling errors that occur while extracting data from a HiRDB and importing it into another HiRDB. Table 7-1 shows the HiRDB Dataextractor error handling procedures.

Table 7-1 HiRDB Dataextractor error handling procedures

Error
HiRDB Dataextractor processing
User's action

Insufficient memory

Message output

Disconnection

Message output to error log file

Termination of processing

Re-execute when sufficient memory becomes available.

Internal conflict

Message output

Disconnection

Message output to error log file

Abnormal termination of processing

Contact the customer engineer.

System call error

Message output

Disconnection

Message output to error log file

Termination of processing

Eliminate the cause of the error and re-execute.

Line error or disconnection from remote system

Message output

Disconnection

Message output to error log file

Termination of processing

In the case of a network error, eliminate the cause of the error and re-execute.

In other cases, contact the customer engineer.

Access error during data import into HiRDB

Message output

Disconnection

Message output to error log file

Termination of processing

Eliminate the cause of the error and re-execute.
If data was extracted from a HiRDB and an error occurred during data import into another HiRDB, HiRDB Dataextractor outputs the JXU7010E message to the data source system. If this is the case, eliminate the cause of the error on the basis of the message output to the error log file that was created by the data import process.

Access error during data extraction from HiRDB

HiRDB message output

Disconnection

Message output to error log file

Termination of processing

Eliminate the cause of the error and re-execute.
If the PDCLTPATH environment variable has been specified, HiRDB's SQL trace information is output to the SQL trace file. Eliminate the cause of the error on the basis of this information.

Access error during data extraction from ORACLE

ORACLE message output

Disconnection

Message output to error log file

Termination of processing

In the case of an SQL analysis error, check the values specified in the column name specification file, table expression specification file, and lock information file, eliminate the cause of the error, and then re-execute.

HiRDB Dataextractor operating environment setup error

Message output

Disconnection

Message output to error log file

Termination of processing

Check the HiRDB environment (such as variables), eliminate the cause of the error, and then re-execute.

HiRDB Dataextractor abnormal termination

Core dump output by OS

Abnormal termination of processing

Contact the customer engineer.

8. Messages

This chapter explains the messages that are issued by HiRDB Dataextractor.

Organization of this chapter

8.1 Overview of messages

8.2 Details of messages

8.1 Overview of messages

This section explains the format of messages issued by HiRDB Dataextractor. Table 8-1 lists the destinations of the HiRDB Dataextractor messages. For the destination of each message, see Table 8-1.

Table 8-1 Destinations of HiRDB Dataextractor messages

Destination | Protocol
TCP/IP | OSI
Extraction 1 | Extraction 2 | Import/File creation | Extraction 2 | Import/File creation
/opt/HIRDBXT/spool/xter | Y¹ | Y² | Y² | N/A | N/A
/opt/HIRDBXT/spool/xtlog | N/A | N/A | N/A | Y² | Y²
Standard output | Y | N/A | N/A | N/A | N/A
Message log file³ | Y | Y | Y | Y | Y

Y: Output.

N/A: Not output.

Extraction 1: Data extraction facility is executed with the xtrep command in order to extract and import data between HiRDBs.

Extraction 2: Data extraction facility is executed via a linkage with VOS3 XDM/XT.

Import/File creation: Data import facility or file creation facility is executed.

¹ Specify a filename that is unique in HiRDB Dataextractor. You can output to a desired file by specifying the -e option in the xtrep command. This file is created when an error occurs during parameter analysis, in which case error messages are output to the standard output only.

² Specify a filename that is unique in HiRDB Dataextractor.

³ When the OS being used is HP-UX, the message log file does not display national character data correctly. Consequently, if national character data is included in the embedded characters (such as a table identifier or column name) of a message text that is output to the message log file, that data is not displayed correctly. In such a case, check the contents of the error log file; the same message is also output to the error log file.

Organization of this section

8.1.1 Message format

8.1.2 Message explanatory format

8.1.3 Message output destinations

8.1.1 Message format

HiRDB Dataextractor outputs messages in the following format:

JXUnnnns message-text

JXU: Identifier of a HiRDB Dataextractor message.

nnnn: Message number.

s: Message severity:

E: Error message (indicates that an error has occurred that prevents execution of a facility)

I: Information message (provides information about the operating status)

message-text: Contents of the message.

8.1.2 Message explanatory format

The following shows the format used to explain each message in this manual:

JXUnnnns

Message text.

Explanation.

S: Processing by HiRDB Dataextractor that occurs when the message is issued.

P: Action that should be taken by the programmer.

Note: A lower-case character string in a message text in the manual is replaced by an actual value during operation.

8.1.3 Message output destinations

Table 8-2 lists the output destination of each message.

Table 8-2 Message output destinations

Message number | Output destination | Remarks
Command entry system | Linkage or target system
Error log file | Standard output | Message log file | Error log file | Message log file
JXU7000E | Y | Y | Y | Y | Y | --
JXU7001E | Y | Y | Y | Y | Y | --
JXU7002E | Y | Y | Y | Y | Y | --
JXU7003E | Y | Y | Y | N/A | N/A | --
JXU7005I | Y | Y | Y | Y | Y | --
JXU7006E | N/A | N/A | N/A | Y | Y | --
JXU7007I | Y | Y | Y | Y | Y | Output only when the xtstart command is used on the linkage or target system.
JXU7008I | N/A | N/A | N/A | Y | Y | --
JXU7009I | N/A | N/A | N/A | Y | Y | --
JXU7010E | Y | Y | Y | N/A | N/A | --
JXU7011I | Y | Y | Y | Y | Y | --
JXU7012I | N/A | N/A | N/A | Y | Y | --
JXU7013E | N/A | N/A | N/A | Y | Y | --
JXU7014I | N/A | N/A | N/A | Y | Y | --
JXU7017I | N/A | N/A | N/A | Y | Y | --
JXU7018I | N/A | N/A | N/A | Y | Y | --
JXU7019E | Y | Y | Y | Y | Y | --
JXU7020E | Y | Y | Y | Y | Y | --
JXU7021E | Y | Y | Y | Y | Y | --
JXU7022E | N/A | N/A | N/A | Y | Y | --
JXU7100E | Y | Y | Y | Y | Y | --
JXU7101E | N/A | N/A | N/A | Y | Y | --
JXU7102E | Y | Y | Y | Y | Y | --
JXU7103E | Y | Y | Y | Y | Y | --
JXU7104E | N/A | N/A | N/A | Y | Y | Output only when OSI is used.
JXU7106E | N/A | N/A | N/A | Y | Y | --
JXU7200E | Y | Y | Y | Y | Y | --
JXU7201E | Y | Y | Y | Y | Y | --
JXU7203E | N/A | N/A | N/A | Y | Y | --
JXU7204E | Y | Y | Y | Y | Y | --
JXU7205E | Y | Y | Y | Y | Y | --
JXU7206E | Y | Y | Y | N/A | N/A | --
JXU7207E | Y | Y | Y | N/A | N/A | --
JXU7208E | Y | Y | Y | N/A | N/A | --
JXU7208I | Y | Y | Y | N/A | N/A | --
JXU7209E | N/A | N/A | N/A | Y | Y | --
JXU7210I | Y | Y | Y | N/A | N/A | --
JXU7211E | Y | Y | Y | N/A | N/A | --
JXU7212E | Y | Y | Y | N/A | N/A | --
JXU7213E | Y | Y | Y | N/A | N/A | --
JXU7214E | Y | Y | Y | Y | Y | --
JXU7215E | Y | Y | Y | Y | Y | --
JXU7216E | Y | Y | Y | Y | Y | --
JXU7217E | Y | Y | Y | N/A | N/A | --
JXU7218E | Y | Y | Y | N/A | N/A | --
JXU7220E | Y | Y | Y | N/A | N/A | --
JXU7221E | N/A | N/A | N/A | Y | Y | --
JXU7222E | N/A | N/A | N/A | Y | Y | --
JXU7223E | Y | Y | Y | N/A | N/A | --
JXU7224E | N/A | N/A | N/A | Y | Y | --
JXU7230I | N/A | N/A | N/A | Y | Y | --
JXU7230E | N/A | N/A | N/A | Y | Y | --
JXU7300E | N/A | Y | N/A | N/A | N/A | --
JXU7301E | Y | Y | Y | N/A | N/A | --
JXU7302E | Y | Y | Y | N/A | N/A | --
JXU7303E | Y | Y | Y | N/A | N/A | --
JXU7305E | Y | Y | Y | N/A | N/A | --
JXU7306E | Y | Y | Y | N/A | N/A | --
JXU7307E | Y | Y | Y | N/A | N/A | --
JXU7308E | Y | Y | Y | N/A | N/A | --
JXU7309E | Y | Y | Y | N/A | N/A | --
JXU7311E | Y | Y | Y | N/A | N/A | --
JXU7312E | Y | Y | Y | N/A | N/A | --
JXU7313E | Y | Y | Y | N/A | N/A | --
JXU7314E | Y | Y | Y | N/A | N/A | --
JXU7315E | Y | Y | Y | N/A | N/A | --
JXU7316E | Y | Y | Y | N/A | N/A | --

Y: Output.

--: Not output.

N/A: Not applicable.

xtrep command entry system: Host at which the xtrep or xtrepO command is entered.

Linkage or target system: One of the following hosts, as applicable:

Host linked to XDM/XT
If the HiRDB is a HiRDB/Parallel Server, messages issued by HiRDB Dataextractor and by HiRDB's database load utility (pdload) may be output to the system manager (MGR). Therefore, in the event of an error, be sure to check the system manager (MGR).

Host used to execute the data import facility or file creation facility

8.2 Details of messages

JXU7000E

INSUFFICIENT MEMORY

Memory shortage occurred.

S: Terminates processing after disconnecting.

P: Re-execute when sufficient memory becomes available.

JXU7001E

LOGICAL ERROR OCCURRED CODE=Uaaa, bbb[, c...c]

Error occurred during internal processing.

aaa: Maintenance code

bbb: Detail code

c...c: Maintenance information

S: Terminates processing after disconnecting.

P: Contact the customer engineer.

JXU7002E

SYSTEM CALL ERROR, FUNC=a...a, ERRCODE=bbb
{NAME=c...c|SIZE=d...d|[e...e]}

System call shown as a...a resulted in an error.

a...a: System call resulting in the error

bbb: Error code

c...c: Filename or service name

d...d: Size of area to be allocated

e...e: Maintenance information

S: Terminates processing after disconnecting.

P: Check the reference manual for the indicated error code and function, eliminate the cause of the error, and then re-execute.

When FUNC=getservebyname
Confirm that the service name in the services file matches the service name in HiRDB Dataextractor's environment variable information setup file (hirdbxt.ini).

When FUNC=connect and errno=239 or 10061 (target system is a Windows version)
Confirm that the service has been started.

When FUNC=LoadLibraryEx, errno=1114, and NAME=%PDDIR%\bin\pdsingle.dll (target system is a Windows version)
If the target HiRDB system was installed with a setup identifier, confirm that the following environment variables are specified in hirdbxt.ini:
- PDDIR
- PDCONFPATH
- PDUXPLDIR

When FUNC=CodeCnvOpen and ERRCODE=-4
If a mapping table for character code conversion that was created with version 07-03 or an earlier version was used, re-create the mapping table.

JXU7003E

ROW LENGTH EXCEEDS 4294967295

HiRDB Dataextractor cannot continue processing because the length of a row exceeded 4 GB.

S: Terminates processing.

P: Check the row lengths in the applicable table and re-execute. If the table contains BLOB or SGMLTEXT columns, make sure the XTLOBBUFSIZE environment variable is specified, and then re-execute.

JXU7005I

END OF a...a RETURN CODE IS bb

HiRDB Dataextractor terminated with return code bb.

a...a: Program name:

PXTCNTL: HiRDB Dataextractor on the data target system (TCP/IP)

PXTOSIL: HiRDB Dataextractor on the data target system (OSI)

xtrep: HiRDB Dataextractor on the data source system (extraction from HiRDB)

xtrepO: HiRDB Dataextractor on the data source system (extraction from ORACLE)

bb: Return code:

0: Normal termination

4: HiRDB's database load utility resulted in an error; overflow or truncation may have occurred.

8: Parameter error

12: Unresumable error occurred.

16: Processing terminated abnormally or internal conflict was detected.

S: Terminates processing.

P: Take one of the following actions:

Return code: 12
Eliminate the cause of the error on the basis of the message output to the error log file or standard output, and re-execute.

Return code: 16
Contact the customer engineer.

JXU7006E

a...a TERMINATED BY SIGNAL, NO=b...b

Program was terminated by a signal.

a...a: Program name:

PXTCNTL: HiRDB Dataextractor's entry program

PXTLOAD: Program started by PXTCNTL

PDLOAD: HiRDB database load utility

PXTMOCT: OSI daemon program

b...b: Number of signal causing program termination

S: Terminates processing.

P: Check other messages, if any, for the cause of the error, and then re-execute. If there are no other messages, contact the customer engineer.

JXU7007I

HiRDB Dataextractor SYSTEM STARTED
{PID=a...a|SYSLOG=b...b}

HiRDB Dataextractor has started.

a...a: HiRDB Dataextractor's process ID

b...b: HiRDB Dataextractor's error log file

S: Starts processing.

JXU7008I

HiRDB Dataextractor SYSTEM
TERMINATED PID=a...a

HiRDB Dataextractor has terminated.

a...a: HiRDB Dataextractor's process ID

S: Terminates processing.

JXU7009I

HiRDB Dataextractor LOAD PROCESS
a STARTED PARTNER JOB NAME=b...b

HiRDB Dataextractor has started data import processing.

a: One of the following:

M: Control processing

F: Input file creation processing

b...b: Name of the XDM/XT job that connected with this processing

S: Starts import processing.

JXU7010E

a...a ERROR OCCURRED, CODE=bb

Error occurred in another program.

a...a: Program name:

PXTCNTL: HiRDB Dataextractor on the data target system

SHELL SCRIPT: User-specified shell script

bb: Error code:

When a...a is PXTCNTL:

4: HiRDB database load utility resulted in an error.

12: Unresumable error occurred while accessing HiRDB Dataextractor, HiRDB, or user-specified shell command.

16: HiRDB Dataextractor terminated abnormally.

When a...a is SHELL SCRIPT:

bb indicates the exit status that is returned by the user-specified shell script.

S: Takes one of the following actions:

When a...a is PXTCNTL:

Error code: 4
Resumes processing.

Error code: Other than 4
Terminates processing.

When a...a is SHELL SCRIPT:

Terminates processing.

P: Take one of the following actions:

When a...a is PXTCNTL:

Error code: 4
Check the execution results listing from the program shown as a...a for errors.

Error code: Other than 4
Eliminate the cause of the error on the basis of the execution results listing from the program shown as a...a, and then re-execute the job.

When a...a is SHELL SCRIPT:

Check the execution results listing from the user-specified shell script for errors.

JXU7011I

a...a ROWS EXTRACT [SUCCESSFULLY]

a...a rows have been extracted.

a...a: Number of rows extracted

SUCCESSFULLY: Displayed with the final number of rows that were output

S: Resumes processing.

JXU7012I

{FILE|DIRECTORY} CREATED NAME=a...a
[COUNT=b...b]

File or directory creation processing has terminated.

a...a: Filename or directory name

b...b: Number of data items

S: Resumes processing.

JXU7013E

{FILE|DIRECTORY} EXIST NAME=a...a

Specified file or directory already exists.

a...a: Filename or directory name

S: Terminates processing.

P: Take one of the following actions, and then re-execute:

Change the name of the file or directory to be created.

Change the appropriate specification so that the existing file or directory can be overwritten.

JXU7014I

EXEC a...a IS b...b

a...a is being executed.

a...a: Event being executed:

pdload ARG: pdload is being executed.

SHELL SCRIPT: Shell script is being executed.

b...b: One of the following is displayed:

a...a: pdload ARG

pdload's execution options

a...a: SHELL SCRIPT

Absolute pathname of the shell script

S: Waits for termination of a...a.

JXU7017E

THIS FUNCTION IS NOT SUPPORT, KIND=a...a b...b

Facility to be executed is not supported by the version in use at the destination. The following this message, HiRDB Dataextractor outputs maintenance information in dump format.

Destination: XDM/XT or HiRDB Dataextractor

a...a: Maintenance information

b...b: Maintenance information (dump format)

S: Terminates processing.

P: Verify that the function being executed is supported by the combination of the versions used with the target system. If this is not applicable, contact the customer engineer.

JXU7018I

FILE CREATED COUNT=aa SUCCESSFULLY

File creation processing has been completed.

aa: Number of data items

S: Resumes processing.

JXU7019I

INVALID ADDRESS MODE,
HiRDB Dataextractor a...a b...b=c...c

HiRDB Dataextractor accessed a program with a different addressing mode.

a...a: HiRDB Dataextractor's addressing mode:

32bit: 32-bit mode

64bit: 64-bit mode

b...b: Target program:

HiRDB

c...c: Target program's addressing mode:

32bit: 32-bit mode

64bit: 64-bit mode

S: Terminates processing.

P: Use the target program's addressing mode, and re-execute.

JXU7020E

MODULE TRACE FILE CREATED NAME=a...a

Module trace file was output.

a...a: Name of the module trace file

S: Terminates processing.

JXU7021E

NOT EXEC a...a

HiRDB Dataextractor was unable to execute the indicated processing.

a...a: Processing whose execution was attempted:

MODULE TRACE: Module trace collection processing

S: Resumes processing.

JXU7022E

CORE FILE IN a...a

The core file storage directory is a...a.

a...a: Name of the core file storage directory

S: Resumes processing.

JXU7100E

COMMUNICATION ERROR OCCURRED
CODE=(aaa, bbbb)[PARTNER=d...d]
[HOSTNAME=e...e]

Error occurred with respect to communication with the target system.

aaa: Processing code:

2: setsockopt socket library

6: Receiving

7: Sending

bbbb: Error code:

TCP/IP used: Socket library's errno

OSI used: TLI function's t_errno

d...d: JOBID or process ID:

XDM/XT: JOBID

HiRDB Dataextractor: PXTCNTL's process ID

e...e: Remote system's host name

This information is displayed only when the remote system is a HiRDB Dataextractor.

PARTNER and HOSTNAME portions are displayed only when OSI is used.

S: Disconnects and terminates processing.

P: Eliminate the cause of the error and re-execute.

TCP/IP used:

Check the Hitachi CSMA/CD Network CD105 (TCP/IP) manual for the socket library's reason code corresponding to the processing code. In the case of a network error, eliminate the cause of the error and re-execute.

For other errors, contact the customer engineer.

OSI used:

Process ID displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host indicated by HOSTNAME. This error file contains the process ID displayed at the beginning of this message.

Process ID not displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host that contains the HiRDB3 system manager. This error file contains the process ID displayed at the beginning of this message.

JXU7101E

a...a CANNOT CONNECT
[PARTNER=d...d] [HOSTNAME=e...e]

Connection establishment with the remote system failed.

a...a: Load name:

PXTCNTL: Load name when TCP/IP is used

PXTOSIL: Load name when OSI is used

d...d: Job ID or process ID:

XDM/XT: Job ID

HiRDB Dataextractor: PXTCNTL's process ID

e...e: Remote system's host name

This information is displayed only when the remote system is HiRDB Dataextractor.

PARTNER and HOSTNAME portions are displayed only when OSI is used.

S: Disconnects and terminates processing.

P: Eliminate the cause of the error and re-execute.

TCP/IP used:

Check the specified port number for an error.

Re-evaluate the combination of HiRDB Dataextractor versions between local and remote systems.

Check; if necessary, revise the value of the XTPCHKTIME environment variable.

OSI used:

Process ID displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host indicated by HOSTNAME. This error file contains the process ID displayed at the beginning of this message.

Process ID not displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host that contains the HiRDB system manager. This error file contains the process ID displayed at the beginning of this message.

Check; if necessary, revise the value of the XTPCHKTIME environment variable.

JXU7102E

CONNECTION CLOSED{CODE= (aaa, bbbb)
|FUNC=c...c CODE=d...d}[PARTNER=e...e]
[HOSTNAME=f...f]

Connection with the remote system was interrupted because of an error.

aaa: Processing code (maintenance code):

6: Receiving

7: Sending

bbbb: Error code (maintenance code):

TCP/IP used: Socket library's errno

OSI used: TLI function's t_errno

c...c: Name of the TLI function resulting in the error

d...d: Error code (maintenance code):

TLI function's t_errno

e...e: Job ID or process ID:

XDM/XT: Job ID

HiRDB Dataextractor: PXTCNTL's process ID

f...f: Remote system's host name

This information is displayed only when the remote system is a HiRDB Dataextractor.

PARTNER and HOSTNAME portions are displayed only when OSI is used.

S: Terminates processing.

P: An error may have occurred on XDM/XT or HiRDB Dataextractor. Correct the error and re-execute.

Process ID displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host indicated by HOSTNAME. This error file contains the process ID displayed at the beginning of this message.

Process ID not displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host that contains the HiRDB system manager. This error file contains the process ID displayed at the beginning of this message.

JXU7103E

CANNOT CONNECT WITH a...a, (b...b)
[PARTNER=c...c]

Could not establish connection with the HiRDB Dataextractor located at the host where data is to be stored.

a...a: Name of the host at the data storage destination

b...b: IP address of the host at the data storage destination

xxx.xxx.xxx.xxx format (xxx: decimal number)

c...c: Job ID or process ID:

XDM/XT: Job ID

HiRDB Dataextractor: PXTCNTL's process ID

PARTNER portion is displayed only when OSI is used.

S: Terminates processing.

P: Eliminate the cause of the error and re-execute.

TCP/IP used:

Check the specified port number for an error.

If the FQDN was specified instead of the host name when HiRDB Dataextractor was executed, use b...b instead of a...a to identify the host that could not be connected.

OSI used:

Process ID displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host indicated by HOSTNAME. This error file contains the process ID displayed at the beginning of this message.

Process ID not displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host that contains the HiRDB system manager. This error file contains the process ID displayed at the beginning of this message.

JXU7104E

COMMUNICATION ERROR OCCURRED,
LOADNAME=a...a HOSTNAME=b...b
[PARTNER=c...c]

Error occurred during communication with another HiRDB Dataextractor.

a...a: Load name of the remote HiRDB Dataextractor

b...b: Name of the host at which a...a is located

c...c: Job ID or process ID:

XDM/XT: Job ID

HiRDB Dataextractor: PXTCNTL's process ID

PARTNER portion is displayed only when OSI is used.

S: Terminates processing.

P: Take appropriate action according to the message issued before this message and the message output by the remote load.

When using OSI, process ID displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host indicated by HOSTNAME. This error file contains the process ID displayed at the beginning of this message.

When using OSI, process ID not displayed with PARTNER
Take appropriate action according to the HiRDB Dataextractor error file located at the host that contains the HiRDB system manager. This error file contains the process ID displayed at the beginning of this message.

JXU7106I

OSI COMMUNICATION PROGRAM IS NOT ACTIVE

HiRDB Dataextractor will retry the requested operation because the program required for OSI communication is not active.

S: Resumes processing.

P: Start the program required for OSI communication (XNF).

JXU7200E

ERROR OCCURRED DURING
DATABASE ACCESS STATUS=aaag
OPERATION CODE=b...b [c...c]

An unresumable error occurred while accessing HiRDB or ORACLE. This message may be followed by a HiRDB or ORACLE message.

aaa: HiRDB SQLCODE or ORACLE error code

b...b: Operation code (internal information)

c...c: HiRDB or ORACLE message

S: Disconnects and terminates processing.

P:

HiRDB

Eliminate the cause of the error on the basis of the HiRDB SQLCODE or HiRDB message, and re-execute. For details about the HiRDB SQLCODE and HiRDB messages, see the HiRDB Messages manual.

ORACLE

Eliminate the cause of the error on the basis of the ORACLE error code or message, and re-execute. In the case of an SQL analysis error, check the values specified in the column name specification file, table expression specification file, and lock information file. For details about the ORACLE error codes and messages, see the ORACLE manual.

JXU7201E

ERROR OCCURRED DURING ENVIRONMENT
SET FUNCTION=a...a [CODE=bbb]

An unresumable error occurred while setting up the HiRDB Dataextractor operating environment.

a...a: Name of environment setup function (internal information), name of environment variable, or section name

If PDUSER is displayed, you must have specified a user ID and password in advance.

bbb: Environment setup function's return value (internal information)

S: Disconnects and terminates processing.

P: Check the HiRDB and HiRDB Dataextractor environment (variables) and re-execute. Also, check that HiRDB has started. If FUNCTION=SECTION NUMBER is displayed, HiRDB Dataextractor's environment variable information setup file (hirdbxt.ini) contains too many sections, in which case correct the file and re-execute.

JXU7203E

a...a IS NOT DEFINED IN ENVIRONMENT
FILE

Error detected in HiRDB Dataextractor's environment variable information setup file.

a...a: Name of the environment variable

S: Disconnects and terminates processing.

P: Check HiRDB Dataextractor's environment variable or HiRDB's environment variables, and re-execute.

JXU7204E

TIMEOUT OCCURRED DURING a...a

Timeout occurred during processing.

a...a: Processing type:

INPUT FILE I/O: Write to input file

RECEIVE DATA: Message receive from remote system

SEND DATA: Message send to remote system

S: Terminates processing.

P: Correct the error on the basis of the messages in the error log or HiRDB database load utility's error file, and re-execute.

INPUT FILE I/O displayed as the type of processing:

Storage table locked
Re-execute after the processing that locks the storage table has terminated.
If necessary, also revise the job schedule so that no more than one import process occurs on a table at the same time.

Storage table not locked
Specify an input file write monitoring time (XTOPNWTIME environment variable) and re-execute. If it has already been specified, increase the value and re-execute.

RECEIVE DATA or SEND DATA displayed as the type of processing:

Check the communication line for problems. If there are no problems with the communication line, increase the communication function's response monitoring time (XTTCPWTIME or XTOSIWTIME environment variable), and re-execute.

JXU7205E

VALUE OF a...a PARAMETER IS INVALID

Parameter value is invalid.

a...a: Name of parameter

S: Terminates processing.

P: Eliminate the cause of the error and re-execute.

JXU7206E

SPECIFIED TABLE a...a.b...b IS NOT
DEFINED IN c...c DICTIONARY

Specified table a...a.b...b is not defined in the dictionary.

a...a: Authorization identifier on the source or target system

b...b: Table identifier on the source or target system

c...c: Type of database

S: Terminates processing.

P: Correct the table name or define the table, and re-execute.

JXU7207E

SPECIFIED LOAD COLUMN NUMBER IS
NOT EQUAL EXTRACT COLUMN NUMBER
IN TABLE a...a.b...b

Number of columns in the import table does not match the number of columns in the extraction table.

a...a: Authorization identifier on the target system

b...b: Table identifier on the target system

S: Terminates processing.

P: Correct the table name or HiRDB definitions, and re-execute.

JXU7208E

DATA CONVERT ERROR CODE=aa COUNT=bb

Data truncation or overflow occurred.

aa: Error code:

01: Data truncation

02: Overflow

bb: Number of errors

S: Terminates processing.

P: Correct the column length on the target system or increase the value of the XTLOBBUFSIZE environment variable, and then re-execute.

JXU7208I

DATA CONVERT ERROR CODE=aa

Data truncation or overflow occurred.

aa: Error code:

01: Character truncation

02: Overflow

S: Resumes processing.

JXU7209E

ERROR OCCURRED DURING DATA PUT
CODE=aa COUNT=b...b [SIZE=c...c]

Write error occurred in the extracted data.

aa: Error code:

01: Size of the output file is invalid

02: There is no more file to be output

b...b: Number of data items

c...c: Data length per line

S: Terminates processing.

P: Take one of the following actions:

Error code: 01

Increase the value of the XTFILESIZE environment variable and re-execute.

Error code: 02

Take one of the following actions and re-execute:

Increase the value of the XTFILESIZE environment variable.

Provide more space in the directory for storing output files.

Add a filename in the -o option.

JXU7210I

DIFFERENCE MAY BE INCLUDE IN a...a.
b...b.c...c

Data truncation, overflow, or rounding error may occur.

a...a: Authorization identifier on the source or target system

b...b: Table identifier on the source or target system

c...c: Name of column to be extracted or imported or the value set in SQLNAMEC in the Column Name Descriptor Area (SQLCNDA). (For details about the Column Name Descriptor Area, see the HiRDB SQL Reference manual.)

S: Resumes processing.

JXU7211E

DATA TYPE OF {a...a.b...b.c...c|ROW|#n...n}
CANNOT CONVERT

Data type cannot be converted due to an invalid data attribute.

a...a: Authorization identifier on the target system

b...b: Table identifier on the target system

c...c: Column name on the target system

n...n: Serial number of the extracted field

S: Terminates processing.

P: Correct the table name or HiRDB definitions, and re-execute.

If ROW is specified in the column name specification file and a storage column contains variable-length data, either remove the specification of ROW or re-define the target data as fixed-length data, and then re-execute.

If ROW is specified in the column name specification file and the import information file is specified, remove either the specification of ROW or the specification of the import information file, and then re-execute.

JXU7212E

DATA LENGTH OF {a...a.b...b.c...c|ROW}
CANNOT CONVERT

Data type cannot be converted due to invalid data length, precision, or scale.

a...a: Authorization identifier on the target system

b...b: Table identifier on the target system

c...c: Column name on the target system

ROW: When ROW is specified in the column name specification file, the total length of columns does not match between the source and target systems.

S: Terminates processing.

P: Correct the table name or HiRDB definitions, and re-execute.

JXU7213E

SPECIFIED RDAREA a...a IS INVALID BECAUSE
TABLE b...b.c...c IS NOT FOUND IN RDAREA

Specified RDAREA a...a does not contain a table.

a...a: Name of RDAREA on the target system

b...b: Authorization identifier on the target system

c...c: Table identifier on the target system

S: Terminates processing.

P: Correct the table name or RDAREA name or define it in HiRDB, and then re-execute.

JXU7214E

PARTITIONING OF SPECIFIED TABLE a...a.b...b IS
NOT SUPPORTED

Specified table partitioning method is not supported.

a...a: Authorization identifier on the target system

b...b: Table identifier on the target system

S: Terminates processing.

P: Correct the table name and re-execute.

JXU7215E

DATA TYPE OF a...a.b...b.c...c NOT
SUPPORT

Conversion of specified combination of attributes is not supported.

a...a: Authorization identifier on the source or target system

b...b: Table identifier on the source or target system

c...c: Column name on the source or target system

S: Terminates processing.

P: Correct the table name or HiRDB definitions, and re-execute.

JXU7216E

NULL DATA CANNOT BE SPECIFIED IN
a...a.b...b.c...c

The column specified in the null value information file has the NOT NULL constraint.

a...a: Authorization identifier on the source or target system

b...b: Storage table identifier on the source or target system

c...c: Column name on the source or target system

S: Terminates processing.

P: Correct the null value information file or HiRDB definitions, and re-execute.

JXU7217E

ARRAY NUMBER INVALID IN
a...a.b...b.c...c

Invalid combination of number of repetition column elements between source system and target system.

a...a: Authorization identifier on the target system

b...b: Table identifier on the target system

c...c: Column name on the target system

S: Terminates processing.

P: Check the number of elements defined in the columns on the source and target systems, correct any errors, and then re-execute.

JXU7218E

DATA VALUE OF a...a.b...b.c...c CANNOT CONVERT
ERROR CODE=dd COUNT=e...e

Data cannot be converted due to an invalid data type.

a...a: Authorization identifier on the source system

b...b: Table identifier on the source system

c...c: Column name on the source system

dd: Error code:

01: Value of DATE-type data is a B.C. year.

02: Value of numeric data resulted in overflow.

e...e: Number of erroneous lines

S: Terminates processing.

P: Use a convertible attribute on the target system or specify extraction conditions to avoid extracting invalid data, and then re-execute.

JXU7220E

a...a IS INVALID IN b...b LINE=c...c

Specification a...a in line c...c in file b...b is invalid.

a...a: Specified information

b...b: Filename

c...c: Line number

S: Terminates processing.

P: Correct the specification in the file and re-execute.

JXU7221E

FES OR BES IS NOT FOUND IN a...a

There is no front-end server or back-end server on the HiRDB unit at host a...a.

a...a: Name of host on the data target system

S: Terminates processing.

P: Change the client settings so that connection is established with a target host where a front-end server or back-end server is located, and then re-execute; or, check and make sure that the HiRDB environment variables specified in the environment variable information setup file are correct for the corresponding server unit, and then re-execute.

JXU7222E

{ENVIRONMENT FILE NAME IN /etc/
inetd.conf|INPUT DATA FILE NAME}
NOT SET UP

ENVIRONMENT FILE NAME IN /etc/inetd.conf displayed:

HiRDB Dataextractor's environment variable information setup filename is missing in the /etc/inetd.conf configuration file.

S: Terminates processing.

P: Check the value of the server program arguments field in the /etc/inetd.conf configuration file, and re-execute.

INPUT DATA FILE NAME displayed:

The input data file to be passed to pdload is not specified.

S: Terminates processing.

P: Take one of the following actions:

Data extraction or import between HiRDBs
Specify the -o or -O option in the xtrep command and re-execute.

Linked to XDM/XT
Specify the TRANSFER JXUMCTL control statement and re-execute.

JXU7223E

TABLE NAME a...a.b...b IS INVALID
ERROR CODE=c...c

Specified table name is invalid.

a...a: Authorization identifier on the target system

b...b: Table identifier on the target system

c...c: Error code:

004: Specified table has the view attribute.

005: Specified table has the FIX attribute.

If 2 is specified in the XTNLDFLT environment variable, data cannot be imported into a FIX table.

S: Terminates processing.

P: Take one of the following actions:

Correct the table name or HiRDB definitions, and re-execute.

If the error code is 005, change the value of the XTNLDFLT environment variable and then re-execute.

JXU7224E

a...a NOT FOUND

a...a was not found.

a...a: Absolute pathname

S: Disconnects and terminates processing.

P: Check if there is a file or directory with the absolute pathname shown as a...a, eliminate the cause of the error, and then re-execute.

When a...a is $PDDIR*/lib/libscomon.sl, $PDDIR*/client/lib/libzclt.sl, $PDDIR*/lib/libssol.so, or $PDDIR*/client/lib/libzclt.so:

Correct the directory path specified in PDDIR in HiRDB Dataextractor's environment variable information setup file, and then re-execute.

HiRDB may have not been installed correctly. Reinstall HiRDB and re-execute.

* $PDDIR is replaced with the actual directory path specified in PDDIR in HiRDB Dataextractor's environment variable information setup file.

JXU7230I

DATA CONVERT ERROR CODE=aa (b...b, c...c-d...d, e...e) [f...f]

An error occurred during character code conversion processing.
This message is output if the number of conversion error detections has not reached the cutoff number specified by the XTUNDEF environment variable.

aa: Error code

01: Data truncation occurred.

03: Column data ends with only a portion of a 2-byte or 3-byte code.

04: Some other code conversion error occurred.

b...b: Indicates one of the following:

- column-number[[subscript]]: Serial number from the beginning of the columns subject to extraction

- Maintenance information

c...c: Start location of the erroneous column (offset from the top of the row)

d...d: End location of the erroneous column (offset from the top of the row)

e...e: Offset of the erroneous data from the top of the row

f...f: Row data (dump format)

Displays the data before conversion.

If multiple messages are displayed for conversion of one row, this information is displayed after the last message. Note that no row data is output to the message log file.

S: Resumes processing.

JXU7230E

DATA CONVERT ERROR CODE=aa (b...b, c...c-d...d, e...e) [f...f]

An error occurred during character code conversion processing.
This message is output if the number of conversion error detections has reached the cutoff number specified by the XTUNDEF environment variable.

aa: Error code

01: Data truncation occurred.

03: Column data ends with only a portion of a 2-byte or 3-byte code.

04: Some other code conversion error occurred.

b...b: Indicates one of the following:

- column-number[[subscript]]: Serial number from the beginning of the columns subject to extraction

- Maintenance information

c...c: Start location of the erroneous column (offset from the top of the row)

d...d: End location of the erroneous column (offset from the top of the row)

e...e: Offset of the erroneous data from the top of the row

f...f: Row data (dump format)

Displays the data before conversion.

If multiple messages are displayed for conversion of one row, this information is displayed after the last message. Note that no row data is output to the message log file.

S: Terminates processing.

P:

When the error code is 01:

Correct the column length at the target system and then re-execute.

When the error code is 03 or 04:

Correct the extracted data and then re-execute.

JXU7300E

ERROR EXIST IN COMMAND LINE USAGE
: a...a

Specified command line is invalid.

a...a: Command line specification:

xtrep: HiRDB extraction command

xtrepO: ORACLE extraction command

S: Terminates processing.

P: Specify the correct command on the command line.

JXU7301E

LITERAL LENGTH OF PARAMETER IN
a...a OPTION EXCEEDS b...b

Length of value for option a...a exceeds b...b.

a...a: Option specification item:

EXTRACT TABLE: Name of extraction table

EXTRACT FILE NAME: Name of table expression specification file

FILE NAME: Name combining the value of the XTTMPDIR environment variable and the value of the -o, -O, or -q option

DIRECTORY NAME: Name combining the value of the XTTMPDIR environment variable and the value of the -b option

b...b: Maximum possible number of characters

S: Terminates processing.

P: Reduce the number of specified characters to no more than bb, and re-execute.

FILE NAME displayed as a...a
Reduce the total length of the values specified in the XTTMPDIR environment variable and the -o, -O, or -q option to no more than bb, and then re-execute.

DIRECTORY NAME displayed as a...a
Reduce the total length of the values specified in the XTTMPDIR environment variable and the -b option to no more than bb, and then re-execute.

JXU7302E

PARAMETER a...a IN b...b OPTION IS
INCORRECT

Value a...a specified in option b...b is invalid.

a...a: Specified value

b...b: Option specification item:

EXTRACT TABLE: Name of extraction table

S: Terminates processing.

P: Correct the specified value and re-execute.

JXU7303E

PARAMETER a...a IN b...b OPTION IS
OUT OF VALUE RANGE

Value a...a specified in option b...b is outside the valid range of values.

a...a: Specified value

b...b: Name of option

S: Terminates processing.

P: Correct the specified value and re-execute.

JXU7305E

a...a OPTION MISSING

Required option a...a is missing.

a...a: Name of option

S: Terminates processing.

P: Specify option a...a and re-execute.

JXU7306E

a...a OPTION CANNOT BE SPECIFIED
WITH b...b OPTION

a...a and b...b are mutually exclusive.

a...a: Name of option or environment variable

b...b: Name of option or environment variable

S: Terminates processing.

P: Specify either a...a or b...b and re-execute.

JXU7307E

a...a OPTION CANNOT BE SPECIFIED
WITHOUT b...b OPTION

Option a...a must accompany option b...b.

a...a: Name of an option or environment variable

b...b: Name of an option or environment variable

S: Terminates processing.

P: Either specify option b...b or omit option a...a, and then re-execute.

JXU7308E

DUPLICATE PARAMETER a...a IN b...b
OPTION

Value a...a is duplicated in option b...b.

a...a: Specified value

If b...b is the -o or -O option value, the message displays the name that combines the values of the XTTMPDIR environment variable and the -o or -O option.

b...b: Name of option

S: Terminates processing.

P: Correct value a...a so that it is not duplicated, and then re-execute.

JXU7309E

a...a [OPTION] CONFLICTS WITH b...b [OPTION]

A combination of options, or of specified values, or of an option and a specified value is invalid.

a...a: Option name or specified value

b...b: Option name or specified value

S: Terminates processing.

P: Check; if necessary, revise the option or specified value and then re-execute.

JXU7311E

INVALID OPTION SPECIFIED, OPTION NAME=a...a

An invalid command option was detected.

a...a: Command option

S: Terminates processing.

P: Eliminate the cause of the error and then re-execute.

JXU7312E

DEFINITION FORMAT ERROR, FILE= a...a, line=b...b

The definition format is invalid in the conversion definition file.

a...a: Name of the conversion definition file

b...b: Row number

S: Terminates processing.

P: Correct the definition on the indicated line in the conversion definition file and then re-execute.

JXU7313E

INVALID CHARACTER CODE, FILE=a...a, LINE=b...b, KIND=c...c, REASON=d...d

An invalid character was detected.

a...a: Name of the conversion definition file

b...b: Line number

c...c: Type

before: Source character code

after: Target character code

d...d: Reason

S: Terminates processing.

P: Use the indicated reason to correct the character code defined on the indicated row in the conversion definition file, and then re-execute.

JXU7314E

OPTION VALUE IS INVALID, OPTION NAME a...a

The value specified in a command option is invalid.

a...a: Command option

S: Terminates processing.

P: Eliminate the cause of the error and then re-execute.

JXU7315E

FILE ACCESS ERROR HAS OCCURRED, OPERATION=a...a, FILE=b...b, ERRNO=c...c

A file manipulation error occurred.

a...a: Type of manipulation

b...b: File name

c...c: Error number

S: Terminates processing.

P: See errno.h or the applicable OS manual for the interpretation of the error number, eliminate the cause of the error, and then re-execute.

JXU7316E

INVALID COMMAND ARGUMENT

A specified command argument is invalid.

S: Terminates processing.

P: Eliminate the cause of the error and then re-execute.

Appendixes

Organization of the appendixes

A. Memory and File Requirements

B. Functional Differences with Windows

C. Functional Differences with Solaris

D. Functional Differences with Linux

E. Functional Differences with AIX

Appendix A. Memory and File Requirements

Organization of this section

(1) Memory requirements

(2) File requirements

(1) Memory requirements

Table A-1 shows the memory requirements for HiRDB Dataextractor. The required memory is allocated in the local memory.

Table A-1 Memory requirements for HiRDB Dataextractor

Type
Process
Procedure size (KB)
Dynamic memory size (KB)
Variables

HiRDB
Extraction process
250
24 + 32 x 2 + B x 2 + 0.15 x C
B: Length of extracted data
C: Number of extracted columns

Import process
200
16 + 32 x 2 + 0.1 x C

XDM/XT
HiRDB extraction process
850
24 + 32 x 2 + B x 2 + 0.15 x C
B: Length of extracted data
C: Number of extracted columns

HiRDB import process
850
180 + 12 x L
L: Number of LOAD JXUMCTL control statements specified

File creation
Extraction process
250
24 + 32 x 2 + B x 2 + 0.15 x C
B: Length of extracted data
C: Number of extracted columns

File creation process
650
16 + 32 x 4

HiRDB

Importing extracted data into HiRDB or creating a file from extracted data and then importing it into HiRDB.

XDM/XT

Data extraction and import between a mainframe database and HiRDB using XDM/XT.

File creation

Data extraction from HiRDB followed by file creation, or file creation from data extracted from a mainframe database using XDM/XT.

(2) File requirements

The formula for determining the size of an output file depends on the value of the XTNLDFLT environment variable.

Table A-2 presents the formulas for determining file size.

Table A-2 Determining file size

Type of file
Formula (bytes)

Output file
Import to HiRDB or creation of binary file
When the value of XTNLDFLT environment variable is 0 or 1¹
c
{ (column-data-length-i⁴)} x n
i=1

When the value of XTNLDFLT environment variable is 2
c
{ (column-data-length-i⁴) + 4 x (c + 1)} x n
i=1

Creation of DAT file²
c
{ (maximum-length-of-character-conversion-for-column-i⁵)} x n
i=1

LOB input file³
LOB-data-length⁶

n: Number of rows

c: Number of column definitions

¹ If 0 is specified in the XTLOBKIND environment variable, a LOB input file is created separately.

² If there is an SGMLTEXT or BLOB column, a LOB input file is created separately.

³ A LOB input file is created for each column.

⁴ For details about the length of column data, see (4) Output file in 4.2.4 Contents of files specified with the xtrep command.

⁵ For the maximum length for a character conversion for a column, see the table below. In the case of repetition columns, you must take into account the number of elements. For details about the data format of repetition columns during creation of a DAT file, see (6) Extracting repetition columns in 3.1.1 Extracting selected data.

Data type | Maximum length of character conversion (bytes)
INTEGER | 11
SMLLINT | 6
DECIMAL | 31
FLOAT | 24
SMALLFLT | 23
CHAR | Defined length + 2
VARCHAR | Real length + 2
NCHAR | Defined length x 2 + 2
NVARCHAR | Real length + 2
MCHAR | Defined length + 2
MVARCHAR | Real length + 2
DATE | 10
TIME | 8
INTERVAL YEAR TO DAY | 10
INTERVAL HOUR TO SECOND | 8
BLOB | Maximum length of absolute path name of LOB input file
SGMLTEXT | Maximum length of absolute path name of LOB input file
BINARY | Real length + 2
TIMESTAMP | 26

⁶ The maximum number of files is as follows:

Number of LOB data columns defined per row x number of rows

Appendix B. Functional Differences with Windows

This appendix explains points that differ from the normal usage procedures when the OS being used is Windows.

Organization of this section

(1) Differences in available facilities

(2) Notes

(3) Environment setup procedure

(4) Startup and termination

(5) Specification differences with HiRDB Dataextractor

(6) Message output destinations

(1) Differences in available facilities

(a) OSI protocol

Only the TCP/IP protocol is supported; the OSI protocol is not supported.

(b) Import operation without creating an output file

You cannot import data into a table without creating an output file.

Data extraction and import between HiRDBs
You must specify the -o or -O option in the xtrep command. If you omit both these options, the HiRDB Dataextractor on the target system outputs the JXU7222E message and terminates with return code 12. If you do not need these files, specify the -O option. If you specify the -o option, HiRDB Dataextractor retains the files at the server host; you can delete them manually once they are no longer needed.

Data extraction and import with mainframe database
To import from a mainframe database into a HiRDB using XDM/XT, you must specify XDM/XT's TRANSFER JXUMCTL control statement. If this control statement is omitted, HiRDB Dataextractor outputs the JXU7222E message and terminates with return code 12. If you do not need these files, specify PURGE YES in the TRANSFER statement. If you specify NO in the PURGE operand or you omit the PURGE operand from the TRANSFER statement, HiRDB Dataextractor retains these files at the server host; you can delete them manually once they are no longer needed.

(2) Notes

Conversion of data types
If an HiRDB data attribute on the target system is VARCHAR and extracted data contains trailing spaces, these spaces will be eliminated when the data is imported.

Network drive specification in XTTMPDIR environment variable
Do not specify a network drive in the XTTMPDIR environment variable.

Specification values of XTPDCFxxx, XTLPRMxxxx, and XTPDSRxxxx environment variables
When you specify the file name with an absolute path name that contains spaces, enclose the path name in quotation marks (").

When HiRDB is installed with a setup identifier
Note the following items for the source and target systems.

Source system:

When you specify the xtrep or xtrepO command, execute it from the command prompt that corresponds to the HiRDB identifier.

Target system:

Specify the following environment variables in each [service-name] section of hirdbxt.ini. You can import data to the HiRDB corresponding to any identifier by specifying the port number corresponding to that service name in the source system.

- PDDIR

- PDCONFPATH

- PDUXPLDIR

(3) Environment setup procedure

(a) Directories and files created by HiRDB Dataextractor

Table B-1 lists the directories and files that are created by HiRDB Dataextractor during installation.

Table B-1 Directories and files created by HiRDB Dataextractor

Directory name and filename | Description | Type
Source | Target
installation-directory | Directory used to store various HiRDB Dataextractor directories and files | Y | Y
installation-directory\bin | Directory used to store HiRDB Dataextractor's executable files (HiRDB Dataextractor's load modules and commands are stored in this directory) | Y | Y
installation-directory \bin\pxtmsvc.exe | HiRDB Dataextractor's executable files | Y | Y
installation-directory \bin\pxtload.exe | Y | Y
installation-directory \bin\xtrep.exe | Files for HiRDB Dataextractor's xtrep command | Y | Y
installation-directory \bin\xtmsgtext.dll | Text files used to output HiRDB Dataextractor messages | Y | Y
installation-directory \conf\hirdbxtc.ini¹ | HiRDB Dataextractor's environment variable information setup file | Y 2 | (Y)
installation-directory \conf\hirdbxt.ini¹ | HiRDB Dataextractor's environment variable information setup file | Y 3 | Y
installation-directory \lib\maptable\euc2jis.map | Mapping table for character code conversion (from EUC to SJIS) | Y | Y
installation-directory \lib\maptable\eucg2j.map | Mapping table for character code conversion (from EUC to SJIS) | Y | Y
installation-directory \lib\maptable\euc2ucs2.map | Mapping table for character code conversion (from EUC to UCS2) | Y | Y
installation-directory \lib\maptable\eucg2u.map | Mapping table for character code conversion (from EUC to UCS2) | Y | Y
installation-directory \lib\maptable\jis2euc.map | Mapping table for character code conversion (from SJIS to EUC) | Y | Y
installation-directory \lib\maptable\jis2ucs2.map | Mapping table for character code conversion (from SJIS to UCS2) | Y | Y
installation-directory \lib\maptable\ucs22euc.map | Mapping table for character code conversion (from UCS2 to EUC) | Y | Y
installation-directory \lib\maptable\ucs22jis.map | Mapping table for character code conversion (from UCS2 to SJIS) | Y | Y
installation-directory\lib\usermap⁴ | Directory containing the user's mapping tables for character code conversion | -- | Y
installation-directory \spool\⁵ | Directory used to store files output during HiRDB Dataextractor operation | Y | Y

Y: Created.

(Y): Created but not used.

Source: Source system

Target: Target system

installation-directory: Directory in which HiRDB is installed

¹ HiRDB Dataextractor creates the environment variable information setup files (hirdbxtc.ini and hirdbxt.ini) during installation. If you install a new version of HiRDB Dataextractor without uninstalling the previous version in the same directory, HiRDB Dataextractor creates environment variable information setup files with the names hirdbxtcXX.ini and hirdbxtXX.ini (where XX is 00 to 99). However, HiRDB Dataextractor uses hirdbxtc.ini and hirdbxt.ini.

² This file is used only when extracted data is to be imported into a HiRDB.

³ This file is used only when XDM/XT is used to extract data from HiRDB and then import it into XDM/RD or create a sequential dataset.

⁴ This file is created when a mapping table is updated for the first time by the xtccnvedt command.

⁵ installation-directory\spool\ contains files that are created dynamically by HiRDB Dataextractor. You must not delete any of these files during HiRDB Dataextractor operation. Also, never delete installation-directory\spool\. The files created in installation-directory\spool\ during HiRDB Dataextractor operation are the same as those created when the UNIX operating system is used.

(b) Environment variables required in order to use HiRDB Dataextractor

HiRDB Dataextractor's environment variables are specified in the files listed below, which are created by HiRDB Dataextractor during installation. These files already contain environment variables; modify them as appropriate to your user environment. These files can be specified at the same time as the HiRDB.ini file, which specifies client environment variables; the values specified for these files have priority.

hirdbxtc.ini

hirdbxt.ini

(i) Environment variables on data source system (for data extraction and import between HiRDBs)

The following is the procedure for specifying the hirdbxtc.ini file:

Format

[individual-environment-name] ~ <alphanumeric characters with no spaces > ((1-64 characters))

Notes

There is no restriction on the number of individual environment names that can be specified, but large files may use up memory and disable operation.

Each section requires at least one environment variable.

If the same section is specified more than once, the first section specified takes effect.

You must specify the brackets ([]) because they indicate the section name.

(ii) Environment variables on data source system (for XDM/XT linkage)

The following is the procedure for specifying the hirdbxt.ini file:

Format

[service-name] ~ <alphanumeric characters with no spaces > ((1-64 characters))

Notes

You can specify a maximum of 16 service name sections.

Each section requires at least one environment variable.

An error results if a service name is duplicated or more service names are specified than the permitted maximum.

You must specify the brackets ([]) because they indicate the section name.

(c) Environment variables to be specified

Table B-2 lists the environment variables that are required in order to use HiRDB Dataextractor. The environment variable names specified in the [HiRDB Dataextractor] section are used as the initial values for the environment variables specified in the other sections.

Some HiRDB versions allow HiRDB environment variables to be specified in HiRDB Dataextractor's environment variable information setup file.

Table B-2 Environment variables required in order to use HiRDB Dataextractor

Environment variable specification
Source system
Target system

HiRDB
XDM/XT

File
hirdbxtc.ini
hirdbxt.ini
hirdbxt.ini

Environment variables specifiable for HiRDB Dataextractor¹
[XTHOST]
[XTPORTNO]
[XTLOGNAME]
[XTTMPDIR]
[XTLOGNAME]
[XTOPNWTIME]
[XTTMPDIR]
[XTLOGNAME]
[XTOPNWTIME]

Environment variables specifiable for HiRDB¹
[PDUSER]²
[PDDIR]²
[PDCONFPATH]²
[PDUXPLDIR]²
[other-environment-variable]
PDUSER²
[PDDIR]²
[PDCONFPATH]²
[PDUXPLDIR]²
[other-environment-variable]
PDUSER²
[PDDIR]²
[PDCONFPATH]²
[PDUXPLDIR]²
All other environment variables are ignored.

HiRDB: Import of extracted data into a HiRDB

XDM/XT: Use of XDM/XT to extract data from HiRDB and then import it into XDM/RD or create a sequential dataset

¹ Environment variables can be specified in each section.

² This environment variable must be set when the HiRDB for data extraction or import uses a setup identifier.

(d) Environment variable specification format

Format

environment-variable-name=[environment-variable-value]

Note

If you omit an environment variable's value, HiRDB Dataextractor assumes that the specified environment variable is not to be set.

Rules

Specify each environment variable on a single line.

A comment begins with the number sign (#) at the beginning of a line and ends at the end of the line (a comment cannot be specified on a line that contains an environment variable).

(e) Files required in order to use HiRDB Dataextractor

Table B-3 lists the files that are required in order to use HiRDB Dataextractor and which differ from the files required when the UNIX operating system is used.

Table B-3 Files required in order to use HiRDB Dataextractor that differ from the files required when the UNIX operating system is used

Filename | Description | Type
Source system | Target system
HiRDB | XDM/XT
installation-directory\conf\ hirdbxtc.ini | Contains the environment variables used for data extraction in order to extract and import data between HiRDBs. | Y | -- | --
installation-directory\conf\ hirdbxt.ini | Contains the environment variables used to import data into HiRDB and to import extracted data into XDM/XT. | -- | Y | Y
hosts file¹ | Contains the target host name at the target system. | Y | -- | --
services file² | Contains the service name and port number for HiRDB Dataextractor. | -- | Y | Y

Y: Required.

--: Not required.

installation-directory: Directory in which HiRDB Dataextractor is installed

HiRDB: Import of extracted data into HiRDB

XDM/XT: Use of XDM/XT to extract data from HiRDB and then import it into XDM/RD or create a sequential dataset

¹ Windows-system-directory\system32\drivers\etc\hosts

² Windows-system-directory\system32\drivers\etc\services

(4) Startup and termination

The following explains the procedures for operating and handling HiRDB Dataextractor that differ from when the UNIX operating system is used.

(a) Starting HiRDB Dataextractor

Start HiRDB Dataextractor at the following hosts:

Host on the target system when data is to be extracted from a HiRDB and then imported into another HiRDB

Host on the source system or the HiRDB host on the target system when XDM/XT is to be linked

The following explains the HiRDB Dataextractor startup procedures for automatic startup and manual startup.

After you set up the services file, Hitachi recommends that you set up HiRDB Dataextractor for automatic startup.

Automatic startup

This procedure starts HiRDB Dataextractor automatically when Windows is started. For automatic startup of HiRDB Dataextractor, you must use the Windows service.

On the Administrative Tools page, double-click the Service icon.

On the Service page, double-click the HiRDB Dataextractor service in the list box.

For Startup Type, select Automatic.

Manual startup

You use this procedure to start HiRDB Dataextractor manually. In this case, HiRDB Dataextractor is started from the Windows service.

On the Administrative Tools page, double-click the Service icon.

On the Service page, select HiRDB Dataextractor from the list box.

Choose the Start button to start HiRDB Dataextractor.

(b) Terminating HiRDB Dataextractor

The following explains the procedure for terminating HiRDB Dataextractor. The Windows service is used to terminate HiRDB Dataextractor.

Termination from the Windows service

On the Administrative Tools page, double-click the Service icon.

On the Service page, select HiRDB Dataextractor from the list box.

Choose the Stop button.

(5) Specification differences with HiRDB Dataextractor

(a) xtrep command

The following explains the xtrep command specifications that are different from when the UNIX operating system is used.

xtrep
                :
                :
     {-o [output-filename]|-O[output-filename]}
     [-a individual-environment-section-name]
                :
                :

-o [output-filename] ~ <pathname> ((1-70 characters))

-O [output-filename] ~ <pathname> ((1-70 characters))
You must specify either the -o or the -O option. The specification details for these options are the same as when the UNIX operating system is used. The name of the output file is determined by the value of the -o or -O option and the value of the XTTMPDIR environment variable on the data target system. Table B-4 shows the names of output files.

Table B-4 Names of output file

Specification | Name of output file
Specification of output filename | Environment variable XTTMPDIR
Y | Y | %XTTMPDIR%\specified-output-filename
N | installation-directory\spool\specified-output-filename
N | Y | %XTTMPDIR%\extraction-table-name-year.month.date-hour.minute.second
N | installation-directory\spool\extraction-table-name-year.month.date-hour.minute.second

Y: Specified.

N: Not specified.

specified-output-filename: Output filename specified in the -o or -O option

%XTTMPDIR%: Value specified in the XTTMPDIR environment variable

Note

Any spaces or commas in a specified output filename or extraction table name are converted to the underscore character (_) in the created filename.

-a individual-environment-section-name ~ ((1-64 characters))
Specify the name of the individual environment section that was specified for the environment variables in the setup file (hirdbxtc.ini). The environment variables in the specified section take effect during execution of HiRDB Dataextractor. When this option is omitted, HiRDB Dataextractor assumes xtrep00 for the xtrep command and xtrepO00 for the xtrepO command.

(b) Notes on command specification

To specify an authorization identifier or table identifier in lowercase letters, enclose it in a character string consisting of a back slash and a quotation mark ( \").

Example

\"aaa\"

If an authorization identifier or table identifier contains a space, enclose it in a character string consisting of a back slash and a quotation mark ( \") and then enclose it in quotation marks (").

Example

"\"a a\""

To specify a path name that contains spaces, enclose the path name in quotation marks (").

If you have specified only a back slash (\) in the XTTMPDIR environment variable, be sure to specify a complete pathname in the -o, -O, or -b option.

(6) Message output destinations

Table B-5 shows the message output destinations.

Table B-5 Message output destinations

Output destination | Source system | Target system
HiRDB | XDM/XT
Error log file (installation-directory\spool\xter) | Y¹ | Y² | Y²
Standard output | Y | -- | --
Event log | Y | Y | Y

Y: Output.

--: Not output.

HiRDB: Import of extracted data to HiRDB

XDM/XT: Use of XDM/XT to extract data from HiRDB and then import it into XDM/RD or create a sequential dataset

¹ If the XTLOGNAME environment variable is omitted, HiRDB Dataextractor assigns a unique filename. You can output messages to a desired file by specifying the -e option in the xtrep command. In such a case, the specified filename takes precedence over the value set in the XTLOGNAME environment variable. If an error occurs during parameter analysis, this file is not created, and HiRDB Dataextractor outputs error messages to the standard output only.

² If the XTLOGNAME environment variable is omitted, HiRDB Dataextractor assigns a unique filename.

Appendix C. Functional Differences with Solaris

This appendix explains points that differ from the normal usage procedures when the OS being used is Solaris.

Organization of this section

(1) Differences in available facilities

(2) Environment variables

(3) Notes

(1) Differences in available facilities

OSI protocol
HiRDB Dataextractor supports only the TCP/IP protocol; it does not support the OSI protocol.

(2) Environment variables

LANG
If you omit the LANG environment variable, HiRDB Dataextractor assumes ja.

LD_LIBRARY_PATH
When you use the xtrep command to extract and import HiRDB data, specify the absolute path of the directory containing the extracting HiRDB's common library in the user environment where the xtrep command is entered. Use this environment variable instead of the existing SHLIB_PATH environment variable.

(3) Notes

When XDM/XT is linked to extract data from HiRDB or to import data into HiRDB, the character code set specified in the LANG environment variable must be the same as the character type specified in the CONVERT XDM/XT control statement. If they are not the same, the results may not be correct.

If the null value information file is omitted, HiRDB Dataextractor assumes ## (SJIS codes X'81948194') as the default null value for the NCHAR and NVARCHAR attributes. If you omit the LANG environment variable or specify ja as its value, the data ## on the extracting HiRDB will not be stored as the null value by the importing HiRDB. To import ## data as the null value, specify ## in UJIS codes as a literal in the null value information file. For details about how to specify a null value information file, see 4.2.4 Contents of files specified with the xtrep command.

If you specify SPACE for a column with the NCHAR or NVARCHAR attribute in the null value information file, HiRDB Dataextractor uses a space (SJIS code X'8140') as the default null value. Therefore, if you omit the LANG environment variable or specify ja as its value, blank data on the extracting HiRDB will not be stored as the null value by the importing HiRDB. To import a space as the null value, specify the space in its UJIS code as a literal in the null value information file. For details about how to specify a null value information file, see 4.2.4 Contents of files specified with the xtrep command.

Appendix D. Functional Differences with Linux

This appendix explains points that differ from the normal usage procedures when the OS being used is Linux.

Organization of this section

(1) Differences in available facilities

(2) Environment variables

(3) Notes

(4) Setting an environment

(1) Differences in available facilities

OSI protocol
HiRDB Dataextractor supports only the TCP/IP protocol; it does not support the OSI protocol.

(2) Environment variables

LANG
If you omit the LANG environment variable, HiRDB Dataextractor assumes ja_JP.eucJP.

LD_LIBRARY_PATH
When you use the xtrep command to extract and import HiRDB data, specify the absolute path of the directory containing the extracting HiRDB's common library in the user environment where the xtrep command is entered. Use this environment variable instead of the existing SHLIB_PATH environment variable.

(3) Notes

When XDM/XT is linked to extract data from HiRDB or to import data into HiRDB, the character code set specified in the LANG environment variable must be the same as the character type specified in the CONVERT XDM/XT control statement. If they are not the same, the results may not be correct.

If the null value information file is omitted, HiRDB Dataextractor assumes ## (SJIS codes X'81948194') as the default null value for the NCHAR and NVARCHAR attributes. If you omit the LANG environment variable or specify ja_JP.eucJP, ja_JP, or ja_JP.ujis as its value, the data ## on the extracting HiRDB will not be stored as the null value by the importing HiRDB. To import ## data as the null value, specify ## in UJIS codes as a literal in the null value information file. For details about how to specify a null value information file, see 4.2.4 Contents of files specified with the xtrep command.

If you specify SPACE for a column with the NCHAR or NVARCHAR attribute in the null value information file, HiRDB Dataextractor uses a space (SJIS code X'8140') as the default null value. Therefore, if you omit the LANG environment variable or specify ja_JP.eucJP, ja_JP, or ja_JP.ujis as its value, blank data on the extracting HiRDB will not be stored as the null value by the importing HiRDB. To import a space as the null value, specify the space in its UJIS code as a literal in the null value information file. For details about how to specify a null value information file, see 4.2.4 Contents of files specified with the xtrep command.

(4) Setting an environment

This item describes a setup file for using HiRDB Dataextractor that has different settings from the normal settings.

If you use RedHat 7 or later, use the following inetd configuration file:

/etc/xinetd.d/xxxx

xxxx: Create the file using the service name registered in the /etc/services file.

(a) Contents

This file sets up the startup of HiRDB Dataextractor.

(b) Examples

If the service name is hxt000, the file name would be /etc/xinetd.d/hxt000.

Example 1: Definition for starting HiRDB Dataextractor

# HiRDB Dataextractor
service hxt000
{
 disable       = no
 socket_type   = stream
 wait          = no
 user          = root
 server        = /opt/HIRDBXT/bin/pxtcntl
 server_args   = /opt/HIRDBXT/conf/xtenv0
}

Example 2: Definition for starting HiRDB Dataextractor with environment variables specified

# HiRDB Dataextractor
service hxt000
{
 disable       = no
 socket_type   = stream
 wait          = no
 user          = root
 server        = /usr/bin/env
 server_args   = XTLOGNAME=XTLOG /opt/HIRDBXT/bin/pxtcntl /opt/HIRDBXT/conf/xtenv0
}

Note: If you have added or modified files, make sure that you restart xinetd with the following command:

/etc/rc.d/init.d/xinetd restart

Appendix E. Functional Differences with AIX

This appendix explains points that differ from the normal usage procedures when the OS being used is AIX.

Organization of this section

(1) Difference in available functions

(2) Environment variables

(3) Notes

(1) Difference in available functions

OSI protocol

HiRDB Dataextractor supports only the TCP/IP protocol; it does not support the OSI protocol.

(2) Environment variables

LANG
You can specify the following values in this environment variable:

Ja_JP (Shift JIS codes)

ja_JP (Japanese-language EUC codes)

If you omit the LANG environment variable, HiRDB Dataextractor assumes Ja_JP.

LIBPATH
When you use the xtrep command to extract and import HiRDB data, specify the absolute path of the directory containing HiRDB's shared libraries in the user environment where the xtrep command is entered.
Use this environment variable instead of the existing SHLIB_PATH environment variable.

(3) Notes

When data is extracted from or imported to a HiRDB table using XDM/XT linkage, the character code set specified in the LANG environment variable must be the same as the character type specified in XDM/XT's CONVERT control statement. If they are not the same, the operating results may not be correct.

Before executing HiRDB Dataextractor, set up syslog. If you omit specification of the XTLOGRETRY environment variable and do not set up syslog, HiRDB Dataextractor will terminate abnormally. To execute HiRDB Dataextractor without output to syslog, specify 0 in XTLOGRETRY.

Index

[Symbols]
[A][B][C][D][E][F][G][H][I][K][L][M][N][O][P][S][T][V][W][X][Z]

(Symbols)

/etc/hosts

specifying

/etc/inetd.conf

specifying

/etc/services

specifying

/opt/HIRDBXT/

/opt/HIRDBXT/bin

/opt/HIRDBXT/bin/xtmsgtext

/opt/HIRDBXT/bin/xtrep

/opt/HIRDBXT/bin/xtstart

/opt/HIRDBXT/lib

/opt/HIRDBXT/lib/maptable/euc2jis.map

/opt/HIRDBXT/lib/maptable/euc2ucs2.map

/opt/HIRDBXT/lib/maptable/eucg2jis.map

/opt/HIRDBXT/lib/maptable/eucg2u.map

/opt/HIRDBXT/lib/maptable/jis2euc.map

/opt/HIRDBXT/lib/maptable/jis2ucs2.map

/opt/HIRDBXT/lib/maptable/ucs22euc.map

/opt/HIRDBXT/lib/maptable/ucs22jis.map

/opt/HIRDBXT/lib/pxtora01.sl

/opt/HIRDBXT/lib/usermap

/opt/HIRDBXT/obj

/opt/HIRDBXT/obj/pxto8160.o

/opt/HIRDBXT/spool/

/opt/HIRDBXT/spool/...

/opt/HIRDBXT/spool/.pden...

/opt/HIRDBXT/spool/.pdin...

/opt/HIRDBXT/spool/.xtpc...

/opt/HIRDBXT/spool/pdcf...

/opt/HIRDBXT/spool/pder...

/opt/HIRDBXT/spool/pdin...

/opt/HIRDBXT/spool/pdnf...

/opt/HIRDBXT/spool/xter

/opt/HIRDBXT/spool/xtlog...

-b option

-d option

-e option

-f option

-g option

-g option

-g option

-H option

-h option

-I option

-I option

-i option

-j option

-L option

-L option

-l option

-m option

-n option

-n option

-O option

-o option

-p option

-q option

-R option

-r option

-s option

-v option

-v option

-w option

-x option

-y option

-z option

$XTTMPDIR/...

$XTTMPDIR/...

(A)

abbreviations defined

abstract data type

function

access error

during data extraction from HiRDB

during data extraction from ORACLE

during data import into HiRDB

ADT

AIX

functional differences with

ARRAY

(B)

batch output pages count (-n option)

batch output pages count (-n option)

bin

binary format

BLOB

BLOB

BLOB

(C)

character code

conversion function

conversion function

converting

converting from EUC to SJIS

converting from EUC to UTF-8

converting from SJIS to EUC

converting from SJIS to UTF-8

converting from UTF-8 to S-JIS or EUC

data types supported for conversion

file to be created

of extracted data, converting

set

set, conversion range

set, convertible

CODECONV

column

adding to extracted data

repetition

column name

specification file

specification file

specification file

specification file

specification file

specification filename

command

argument

format

name

communication configuration definition information file

communication configuration definition information file

specifying

communication configuration definition information filename

conflict, internal

control process

conventions

abbreviations

diagrams

fonts and symbols

KB, MB, GB, and TB

version numbers

(D)

dat

DAT format

data extraction

between HiRDBs on personal computers

between HiRDBs on workstations

between mainframe and HiRDB on personal computer

between mainframe and HiRDB on workstation

facility

data format

data import

between HiRDBs on computers

between HiRDBs on workstations

between mainframe and HiRDB on personal computer

between mainframe and HiRDB on workstation

facility

specifying method

data transfer, preparing for

data type

comparison by HiRDB Dataextractor

conversion by HiRDB Dataextractor

conversion by HiRDB Dataextractor

converting

of extracted data, converting

database load utility

database load utility

diagram conventions

disconnection from remote system

(E)

environment

for execution examples

setup procedure

variable

variable, information setup file

variable, information setup filename

variable, specification method

variable, specifying

variable, specifying HiRDB Dataextractor's information setup file

variable, specifying information setup file

error

log file

log file

log file

log file

log filename

extracted data storage method (-d option)

extraction

conventions

extracting data by a line-by-line interface

extracting selected data

selecting columns to be extracted

selecting rows to be extracted

sorting columns to be extracted

sorting rows to be extracted

extracts

extracts

(F)

field number

file

creating

creating, using data extracted from HiRDB database at personal computer

creating, using data extracted from HiRDB database at workstation

creating, using data extracted from mainframe database

creating, using data extracted from ORACLE database at personal computer

creating, using data extracted from ORACLE database at workstation

creation facility

naming method, LOB input file

naming method, LOB input file storage directory

naming method, output file

requirements

specifying name for created

to be created, format of

FIX attribute

flag arguments

font conventions

front end server name

(G)

GB, meaning of

(H)

HIGH

HiRDB

HiRDB Dataextractor

abnormal termination

environment variable information setup file

execution examples of

installing

operating environment setup error

starting, on data source system

starting, on data target/file creation system

starting, using OSI

starting, using TCP/IP

terminating, on data source system

terminating, on data target/file creation system

terminating, using OSI

terminating, using TCP/IP

HiRDB Text Search Plug-in

HP-UX

(I)

identifier

authorization

authorization

table

table

import

conventions

information file

information file

information filename

storing data by RDAREA

storing data by table

index creation method (-i option)

index creation mode (-i option)

initial value

input file creation process

(K)

KB, meaning of

(L)

LANG

LD_LIBRARY_PATH

LIBPATH

line error

Linux

functional differences

literal

hexadecimal

loader parameter specification function

loader parameter specification function

LOB input file

LOB input file

storage directory

storage directory

storage directory name

lock

information file

log acquisition method (-l option)

log acquisition mode (-l option)

LOW

(M)

MB, meaning of

memory

insufficient

requirements

message

explanatory format

format

output destinations

(N)

NOCODECONV

NOT NULL constraint

null value

default

default, selecting

handling method

information file

information file

information file

information file

information filename

NULLELM

NUM

(O)

operating procedure

option

option flag

ORACLE

ORACLE

ORACLE

ORDER BY clause (SELECT statement)

OSI protocol

OSI protocol

OSI protocol

output

file

file

file

file

file, creating

filename

listing, during data extraction

listing, during data import

overflow error during data type conversion

(P)

PATH

PDBLKF

PDCLTPATH

PDCONFPATH

PDDIR

PDFESHOST

PDHOST

pdload

pdload

command line information file

command line information file, setting

control information file's source statement information file

execution results

parameter specification

PDNAMEPORT

PDSERVICEGRP

PDSQLTRACE

PDUSER

port number

progress message output interval

PXTCNTL

PXTCNTL

(S)

SELECT statement

selection expression

selection expression

selection expression (ROW specified)

selection expression

ROW specified

separator character

SGMLTEXT type

SGMLTEXT type

SGMLTEXT type

shell script

executing

filename

SHLIB_PATH

Solaris

functional differences with

SPACE

SQL trace file

SQL user specification function during data extraction

SQL user specification function during data extraction

startup

automatic

manual

symbol conventions

syntax conventions

system call error

(T)

T selector value, local host's

T_selector

table

expression specification file

expression specification file

expression specification file

expression specification file

expression specification filename

name information file

name information file, setting

preparing

target host name

TB, meaning of

TCP/IP protocol

TCP/IP protocol

TCP/IP protocol

TZ

(V)

version number conventions

(W)

WHERE clause (SELECT statement)

Windows

functional differences with

(X)

XDM/RD

XDM/XT

XDM/XT

XTARRAY

XTCLMxxxx

XTCNDSKP

XTDPERMIT

XTERRLEVEL

XTEXTRACTDB

XTFESHOST

XTFILESIZE

XTFPERMIT

XTHOST

XTLCKxxxx

XTLOBBUFSIZE

XTLOBKIND

XTLOCALE

XTLOGNAME

XTLOGRETRY

XTLPRMxxxx

XTLPRMxxxx

XTNLDFLT

XTOPTNWTIME

XTORAUSER

XTOSIWTIME

XTPCHKTIME

XTPDCFPATH

XTPDCFxxxx

XTPORTNO

xtrep command

xtrep command

combination of options

xtrepO command

xtrepO command

combination of options

XTSQL

xtstart command execution file

xtstart command execution shell, specifying

XTSTRETRY

XTTBLxxxx

XTTCPWTIME

XTTEMPNAM

XTTMPDIR

XTTRCDIR

XTUNDEF

XTWHExxxx

XTWRTWTIME

XTXHOST

(Z)

ZERO

zero-length data storage (-z option)

Trademarks

AIX is a registered trademark of the International Business Machines Corp. in the U.S.
HP-UX is a product name of Hewlett-Packard Company.
Itanium is a registered trademark of Intel Corporation or its subsidiaries in the United States and other countries.
Linux is a registered trademark of Linus Torvalds.
Microsoft is a registered trademark of Microsoft Corp. in the U.S. and other countries.
ORACLE is a registered trademark of Oracle Corporation.
Solaris is a trademark or registered trademark of Sun Microsystems, Inc. in the United States and other countries.
Sun Microsystems is a trademark or registered trademark of Sun Microsystems, Inc. in the United States and other countries.
The right to use the trademark DCE in Japan is sub-licensed from OSF.
UNIX is a registered trademark of The Open Group in the United States and other countries.
Visual C++ is a registered trademark of Microsoft Corp. in the U.S. and other countries.
Windows is a registered trademark of Microsoft Corp. in the U.S. and other countries.
Windows Server is a registered trademark of Microsoft Corp. in the U.S. and other countries.
X/Open is a registered trademark of X/Open Company Limited in the U.K. and other countries.
Other products and company names mentioned in this document may be the trademarks of their respective owners. Throughout this document Hitachi has attempted to distinguish trademarks from descriptive terms by writing the name with the capitalization used by the manufacturer, or by writing the name with initial capital letters. Hitachi cannot attest to the accuracy of this information. Use of a trademark in this document should not be regarded as affecting the validity of the trademark.