CHAPTER 5 Moving Data In and Out of Databases
175
Redirecting output
and messages
The
>&
redirection symbol redirects all output including error messages and
statistics for the command on which it appears. For example:
SELECT *
FROM employee
>& empfile
Do not enclose the file name in quotation marks.
This example outputs the
SELECT
statement to the file empfile, followed by the
output from the
SELECT
statement and some statistics pertaining to the
command.
The >& redirection method is useful for getting a log of what happens during
a
READ
command. The statistics and errors of each command are written
following the command in the redirected output file.
NULL value output
The most common reason to extract data is for use in other software products.
The other software package may not understand NULL values, however.
The DBISQL option
NULLS
allows you to choose how NULL values are
output. Alternatively, you can use the
IFNULL
function to output a specific
value whenever there is a NULL value.
For information on setting DBISQL options, see “SET OPTION statement” in
Adaptive Server IQ Reference Manual.
Bulk loading data using the LOAD TABLE statement
The
LOAD TABLE
statement is used for efficient importing of data from a text
or binary file into an existing database table. It loads data into any column
indexes you have defined, as well as any created automatically.
In order to use the
LOAD TABLE
statement, you need INSERT permission on
the table.
See the description of the
ON FILE ERROR
load option for what happens when
errors occur during a load.
Summary of Contents for Adaptive Server IQ 12.4.2
Page 1: ...Administration and Performance Guide Adaptive Server IQ 12 4 2 ...
Page 16: ...xvi ...
Page 20: ...Related documents xx ...
Page 40: ...Compatibility with earlier versions 20 ...
Page 118: ...Troubleshooting startup shutdown and connections 98 ...
Page 248: ...Importing data by replication 228 ...
Page 306: ...Integrity rules in the system tables 286 ...
Page 334: ...Cursors in transactions 314 ...
Page 396: ...Users and permissions in the system tables 376 ...
Page 438: ...Determining your data backup and recovery strategy 418 ...
Page 484: ...Network performance 464 ...
Page 500: ...System utilities to monitor CPU use 480 ...
Page 514: ...Characteristics of Open Client and jConnect connections 494 ...
Page 536: ...Index 516 ...