========================================================================
M I C R O F O C U S
O P E R A T I N G S Y S T E M E X T E N S I O N S
V4.0.5
Running Under The DG/UX
Operating System Version 5.4R3.10
On The AViiON
========================================================================
REBUILD
========
This document describes the Rebuild facility supplied with OSX to enable
you to port files between Micro Focus COBOL for DOS, Windows and OS/2 and
Micro Focus COBOL for UNIX and to maintain these files after porting.
TABLE OF CONTENTS
==================
OVERVIEW
Indexed File Reorganization
Recovery of Corrupt Indexed Files
Conversion of Files
OPERATION
Rebuild Options
Examples of Operation
Parameter Files
Redirection of Information
General Notes
SYSTEM PARAMETERS
ERROR, INFORMATION AND WARNING MESSAGES
Errors
Information Messages
Warning Messages
OVERVIEW
========
The File Management utility, Rebuild, provides a number of facilities to
improve the management of data files. The principal facilities offered
are:
o indexed file reorganization.
o recovery of corrupt indexed files.
o conversion from Microsoft v1 and v2 file formats (see the
Compatibility Guide for details of how to do this).
o conversion from LEVEL II V2.5 COBOL, Btrieve and C-ISAM file formats.
References to the LEVEL II V2.5 COBOL file format in this chapter mean
the file format created by the LEVEL II V2.5 COBOL system running on DOS.
Files created by LEVEL II COBOL on UNIX or XENIX are not handled.
You use Rebuild to reorganize indexed files, recover corrupt indexed
files and convert files of other formats into formats used by this COBOL
system.
Indexed File Reorganization
===========================
As indexed files are updated, by adding, deleting and altering records,
the index and data structures become disjointed, making processing less
efficient. In addition, space left by deleted records is not always
reused, thus making the file bigger than it needs to be. After a large
number of changes have been made, it is worth reorganizing an indexed
file to rebuild the data and indices in an ordered sequential fashion and
reclaim any free space, thus providing optimum performance and integrity.
Recovery of Corrupt Indexed Files
=================================
An index can become corrupt if, for example, a power loss occurs when a
program has opened and changed an indexed file, but has not yet closed
it. If a COBOL program subsequently attempts to open this file, then the
RTS will detect that the file was not closed properly and will return a
file status error for "Corrupt Index file". You cannot use the file at
all without first recovering its integrity.
Rebuild can recover corrupt indexed files for you. If the data portion of
the file is intact and only the index portion is corrupt, then Rebuild
can generate a new index (.idx file) from the data with no information
loss. If the data portion of the file is corrupt then Rebuild can rebuild
a complete new indexed file, both data and index portions, but there will
be a loss of information as Rebuild discards any corrupt data records
that it encounters.
Conversion of Files
===================
Rebuild enables you to convert files in LEVEL II 2.5 COBOL, Btrieve
format or C-ISAM format into files for use with this system.
OPERATION
=========
The Rebuild utility is a non-interactive utility, which accepts all of
its parameters from the command line, or from parameter files named on
the command line. See the section Parameter Files later in this chapter
for details of how to create a parameter file.
Note: The "/" characters shown in the following formats for introducing
parameters are for DOS, Windows and OS/2. On UNIX, please replace
these "/" characters by "-" characters.
The format of the command line is, for rebuilding an index:
rebuild in-file [/c..] [/k..] [/i] [/v] [/e]
and for reorganization:
rebuild in-file,out-file [/c..] [/d] [/x..] [/i] [/v]
and for conversion:
rebuild in-file,out-file [/s..] [/o..] [/r..] [/t..]
[/k..] [/c..] [/i] [/v]
where:
in-file is the name of the file, including its extension,
to be rebuilt/reorganized.
out-file is the name of the file, including its extension,
to contain the result. The root of the file-name
must be different from that of in-file.
/c specifies the type of compression to enable on a
file.
/d causes Rebuild to continue from the beginning of
the next record if it finds that the data part of a
record in an indexed file is corrupted.
/e prevents an illegal duplicate key from aborting the
Rebuild process.
/i causes Rebuild to display information.
/k defines the key structure of the output file.
/n causes Rebuild to display information without
processing the file.
/o defines the organization of the input file; this
allows conversion of sequential and relative files
into indexed files.
/r defines the record structure of the input file and
output files.
/s allows conversion of C-ISAM, LEVEL II V2.5 COBOL
and Btrieve files into the indexed file format used
by this system.
/t specifies the index file format of the output file.
/v causes Rebuild to display a running record count.
/x indicates the key-of-reference.
The utility assumes that an index rebuild is required instead of a
reorganization if no output file is specified. A rebuild with no options
can only be achieved if the key information in the index file is not
corrupt. If the index part (.idx) of the indexed file does not exist,
then it is possible to completely rebuild it by additionally specifying a
key structure option. This process also makes it possible to replace the
key structure of an existing indexed file with an alternative structure,
simply by running Rebuild in this mode with a new key specification.
Environment variables named in-file or out-file cause filename mapping.
Rebuild Options
===============
Various options are available with the Rebuild utility. These are
described below. Some of the options are followed by parameters providing
the information. The option letter can be separated from its parameters
by an optional colon (:). Options may be placed anywhere within the
command, and are free-format with spaces allowed between any fields.
/c
The /c option allows the specification of compression on files. The
parameters are the letter d for data compression followed by an integer,
and the letter i for index compression followed by an integer. The
integer for data compression must be in the range 0 to 255 where 0
denotes no compression, values of 1 through 127 are reserved, and 128
through 255 are for user-defined compression routines. The integer for
index compression must be in the range 0 to 7 which corresponds to the
type of compression:
1 - compression of duplicates
2 - compression of leading characters
4 - compression of trailing spaces
You can specify any combination by adding these values together. Zero (0)
specifies no index compression.
For example:
/c:d1i6 Specifies data compression routine 1, and index
compression of leading characters and trailing
spaces.
/ci1 Specifies index compression of duplicates only.
Data compression applies only to an output file; index compression can
apply to an output file or the rebuild of an existing file. The /c
options operate in a similar manner to the Compiler directives
DATACOMPRESS and KEYCOMPRESS. Refer to the appendix Directives for
Compiler for details of the values available.
/d
The /d option causes Rebuild to continue from the beginning of the next
record if it finds that the data part of a record in an indexed file is
corrupted. If the /d option is not set, Rebuild returns file status error
9/18 (Read part record error: EOF before EOR or file open in wrong mode)
when it encounters a corrupted record.
When the /d option is specified, the input file's file header is read in
and the output file is given the same attributes.
This option works best with decompressed files which give 9/18 errors
when rebuilding. Rebuild does try to recover other file types but its
resulting output may not be what you are expecting.
If you specify other Rebuild options (for example, /k) with the /d
option, then the other options take precedence over the details in the
file header.
/e
When rebuilding a corrupt file, or a file with a new key structure (/k
option used), records may be encountered with an illegal duplicate key.
Without the /e option this causes Rebuild to terminate with an "Error on
output file - status 22" error. However, if the /e option is used,
Rebuild reports the duplicate, and continues to process the remaining
records. Note that the record with the duplicate key is not written.
/i
When the /i option is selected, Rebuild will display information about
the input and output files, including record lengths, file type and key
structure. Note that it is not possible to obtain information about a
file without actually invoking one of the operations.
For example, the information for the index rebuild:
rebuild mast/i
Rebuild successful - records read=49
File : MAST
Largest record length -
353
Smallest record length - 353
Average record length -
353
Organization - Indexed
Recording mode - Fixed
Maximum record length - 353
Minimum record length - 353
Keys description:
Start char Length
Key - 0
1 +9
/k
The /k option defines the key structure for an indexed file. This is used
for rebuilding the index of an indexed file where the index part is
missing or corrupt. The parameters for this option define the keys. The
definition of a key is separated from the definition of the next key by a
colon (:). Each key can be defined as a number of parts (split key), each
part being separated by a comma (,). The key part is defined by start
character position and length in characters, separated by a plus (+) or
L. Alternate keys (those other than the first defined) can be terminated
by an additional parameter, the character d, if they are defined as WITH
DUPLICATES. The first character position in a record is position 1.
For example:
/k:1+20
defines a single key, starting at character position 1, length 20
characters
/k:5+5:20+1d:40+2,43+10
defines three keys, the third being split, and the second allowing
duplicates. The first key, the record key, starts at character position
5, length 5; the second key, an alternate key allowing duplicates, starts
at 20, length 1; and the third key, a split alternate key, has two parts,
the first starting at 40, length 2, the second at 43, length 10.
This option applies only to an existing file, unless you are using it to
create an index for a relative or sequential file (see the section The /o
Option) for which you are allowed to specify an output file.
/n
The /n option causes Rebuild to display information about the file, as
for /i, but without doing any other processing on the file.
/o
The /o option defines the organization of the file to be converted. If
the parameter is omitted, indexed is assumed. The organization is
identified by a single letter parameter, as follows:
/o:s sequential
/o:r relative
/o:i indexed (the default)
The output file has the same organization as the input file, but in a
format suitable for this COBOL system. However, you can create indexed
files from sequential and relative files by adding the letter i after the
s or r. To create an index, you specify the key structure with the /k
option. The index file along with its data part is created separately to
the original, so you must specify a name for the output file.
For example:
/o:ri/k:1+2:3+10d
converts a relative file into an indexed file with the key structure
specified.
Notes:Files of the format used by this COBOL system which are processed
by Rebuild must have a variable structure file header. Therefore,
fixed length sequential or fixed length relative files are not
processed because they do not have variable structure file headers.
You can create fixed length sequential or relative files with
variable structure file headers by retaining the record length
information in the COBOL creating program and by adding a RECORDING
MODE IS VARIABLE clause to the FD of your program.
/r
The /r option defines the record lengths and recording mode of a file.
Usually, this information is obtained by Rebuild from the input file and
transferred directly to the output file. However, when converting to and
from Btrieve format files using the /s and /t options, you must consider
the following. Some index file features are implemented differently by
Btrieve. An example is that Btrieve does not store the maximum record
length. Therefore, on conversion from a COBOL format file to a Btrieve
file and back again, certain record length and recording mode information
can be lost. This makes the file unreadable to a COBOL program using the
original file description. Using the /r option, you can specify the
record length and recording mode information on the command line when
converting to retain the correct record definitions. You can determine
the correct options from the COBOL format file using the /n information
option.
For example:
/r:f record-length
Specifies a fixed length record format with records of length
record-length; for example, /r:f100.
/r:v min-record-length max-record-length
Specifies a variable length format with the maximum and minimum record
lengths separated by a hyphen; for example, /r:v100-200.
/s
The /s option is for converting file formats used by other COBOL systems
to the format used by this system. You specify the input file format as
follows:
-------------------------------------------------------------------------
Format Description
-------------------------------------------------------------------------
/s:btrv
/s:c-isam
/s:lii
/s:mf
/s:mf4 Btrieve format.
C-ISAM format.
LEVEL II V2.5 COBOL format.
Format used by this COBOL system.
Duplicate key format used by this system.
For example:
/s:c-isam
converts a C-ISAM format file into the format used by this system.
By default the output file is in the format used by this system, but this
option can be used in conjunction with the /t option to convert from one
file format to another while reorganizing the file at the same time. You
cannot use this option to rebuild a corrupt or deleted index of a C-ISAM,
a LEVEL II V2.5 COBOL or a Btrieve format file by means of a command line
such as:
rebuild infile.dat /s:c-isam
Only indexed files in the format used by this system can be rebuilt. You
should use the /s option to convert your files into this format so that
they can be rebuilt in the event of corruption.
When rebuilding the index of a duplicate key format (mf4) file, you
should specify the /s:mf4 option on the command line otherwise Rebuild
attempts to process the command line as if it is a normal format file
(mf). For example:
rebuild infile.dat /k:1+10:10+2d /s:mf4
I/O operations on Btrieve files are performed by a separate Btrieve file
handler. You must invoke this before Rebuild performs any conversions
involving Btrieve files. If you do not, error 9/27 (Device not available)
is returned. See your Btrieve documentation for details of how to set up
and invoke the Btrieve file handler.
/t
The /t option allows the specification of the index file format of the
output file. You specify the output file format as follows:
-------------------------------------------------------------------------
Format Description
-------------------------------------------------------------------------
/t:btrv
/t:c-isam
/t:lii
/t:mf
/t:mf4 Btrieve format.
C-ISAM format.
LEVEL II V2.5 COBOL format.
Format used by this system.
Duplicate key format used by this system.
This option applies only to an output file so out-file must be specified.
I/O operations on Btrieve files are performed by a separate Btrieve file
handler. You must invoke this before Rebuild performs any conversions
involving Btrieve files. If you do not, error 9/27 (Device not available)
is returned. See your Btrieve documentation for details of how to set up
and invoke the Btrieve file handler.
/v
When the /v option is present, Rebuild will display a record count which
it increments as it processes the file. This is useful if you want to
keep track of how Rebuild is progressing.
-------------------------------------------------------------------------
Warning:
-------------------------------------------------------------------------
: Do not use the /v option if you are redirecting the output.
/x
The /x option defines the key-of-reference, which is used to define the
order in which the data will be written when reorganizing an indexed
file. The parameter for this option is the number of the key to be used.
The record key is 0, the alternate keys are numbered, starting at 1, in
the order they are specified in the SELECT statement in the creating
program. If no /x option is specified then the record key (key 0) is
assumed.
For example:
/x:2
causes the data to be organized in the order specified by the second
alternate key in the SELECT clause of the creating program.
Examples of Operation
=====================
rebuild badms001.dat, ms001.dat/i
reorganizes the given file, assuming it is an indexed file in the
format used by this system. The data will be written in the order of
the record key, and information displayed when the reorganization is
complete.
rebuild badms001.dat, ms001.dat/x:3
reorganizes the given file, assuming it is an indexed file in the
format used by this system. The data is written in the order of the
third alternate key.
rebuild ms001.dat
rebuilds the index of the given file, assuming it is an indexed file
in the format used by this system, and that the index (.idx) file is
still present, and the key information held therein is not corrupt.
rebuild ms001.dat/k:1+20/i
rebuilds the index of the given file, assuming it is an indexed file
in the format used by this system. The index (.idx) file does not
need to exist, and is ignored if it does. It will be completely
recreated using the key definition specified on the command, which
need not correspond to the key definition used when the file was
created. Information about the file will be displayed when the
rebuild ends.
rebuild infile.dat,outfile.dat /t:btrv
converts a file in a format used by this COBOL system to a Btrieve
format file.
rebuild infile.dat,outfile.dat /s:btrv /t:mf /r:v12-20
converts a Btrieve format file to a format used by this COBOL system
and sets the recording mode to variable, the minimum record length to
12 and the maximum record length to 20.
rebuild infile.dat, outfile.dat /s:c-isam /c:d1
converts a C-ISAM format index file into the format used by this
system and compresses the data part.
rebuild infile.dat, outfile.dat /o:ri /k:1+2:3+10d /c:i7
generates an index with all types of key compression for a relative
file.
rebuild infile.dat, outfile.dat /s:lii /t:lii
reorganizes a LEVEL II V2.5 COBOL format file and retains the LII
structure on the output file. It is possible to combine /s and /t
with other formats in a similar manner.
set data=\tmp.dat
rebuild data /i
reorganises and displays information about the file \tmp.dat.
Parameter Files
===============
At any point on the command line, an at character (@) followed by a
file-name indicates that parameters should be taken from the named file.
The contents of the file are treated as if they were part of the command
line, replacing the @file-name.
The parameter file is an ASCII text file. The parameters can be specified
in free-format, with spaces being non-significant. (Line ends are treated
as spaces.) The file must not be bigger than 1024 bytes. Comments can be
included in the file by preceding them with an asterisk (*). Anything
following the asterisk is treated as a comment, up to the end of the
line.
For example:
rebuild badms001.dat, ms001.dat @ms001.par
where ms001.par is an ASCII text file containing the following line:
/k:1+20, 25+5:40+12:60+3, 85+10d
or the following lines (which are equivalent to the line above):
* Works master file - key parameters
/k:
1+20 , * prime key - first part
25+ 5 : * - second part
40+12 : * 1st alternate key
60+ 3 , * 2nd alternate key (with duplicates)
* - first part
85+10d * - second part
If a parameter in a parameter file is in error, then a suitable message
is displayed. The parameter file line in error is not displayed, but the
command line is.
Redirection of Information
==========================
All information displayed by the utility can be redirected to a text file
using the standard operating system redirection, > for creating a new
file and >> for extending an existing file. Hence, the results of a
number of rebuilds in a batch stream can be collected as the stream is
processed, and viewed on completion.
For example:
rebuild oldms001.dat,ms001.dat /k:1+20 /i > rebuild.prt
rebuild oldrt549.seq,rt549.seq /i >> rebuild.prt
rebuild badms001.dat,ms001.dat@ ms001.par >> rebuild.prt
causes the information for all three operations to be placed in the text
file, rebuild.prt, one after the other. This can be viewed later using a
text editor or the operating system TYPE command. Note that you must not
use the /v option when you are redirecting output.
General Notes
=============
o We recommend that you make a backup copy of the file being rebuilt or
reorganized before using Rebuild. Rebuild takes every precaution to
prevent the original files being corrupted, but it can happen if the
command line is incorrectly specified. Also, when doing an index
rebuild, the original index is overwritten, so it would be wise to
preserve it in case there are any subsequent problems. For indexed
files in the format used by this system, you should save both the
data and the index (.IDX) file.
o The facility to rebuild the index of an indexed file does not retain
the information held in the original about free space in the data
file (Data Free Space Record). Consequently, this free space cannot
be reused and your file may grow bigger than necessary. To overcome
this problem you are recommended to reorganize the file after you
have rebuilt the index, thus removing all of the free space.
(Free space consists of the spaces in the data file occupied by
deleted records. Information about these areas is normally retained,
and the areas are normally reused for new records as appropriate.)
When the rebuild process is complete, the data file is changed
because a blank Data Free Space Record is added to the end of the
file. Each time you rebuild the index a new record is added.
Consequently, several rebuilds, without intervening reorganizations,
cause the data file to grow. Again, this problem can be eliminated by
reorganizing the file, causing all the Data Free Space Records to be
removed, and a single new blank one added. (See the appendix File
Formats for more details about indexed file structures.)
SYSTEM PARAMETERS
=================
A set of special parameters can be specified immediately following
Rebuild on the command line. These parameters are present for use during
development, testing and support of Rebuild. Each parameter consists of
two slashes followed by a letter followed by a space.
Note: The "//" characters are for DOS, Windows and OS/2. On UNIX, please
replace "//" by "--".
//q prevent banners from being displayed
//v display version number of Rebuild program itself
ERROR, INFORMATION AND WARNING MESSAGES
=======================================
Rebuild will output an Error, Information or Warning message if you do
not specify the correct command line when rebuilding, converting or
reorganizing an indexed file. The following sections list these messages
with an explanation of the message and, for Error and Warning message, a
solution.
Errors
======
When an error is encountered, the command line is displayed, followed by
an error message. For command line errors, a caret (>) is displayed under
the point in the command line that the error was detected. The program
sets the return code to a value other than zero to indicate the type of
error that has occurred. The code can be tested in a batch file using the
IF ERRORLEVEL command.
The most likely cause of errors is specifying parameters to Rebuild that
do not correctly represent the input file. In most cases it is difficult
for the utility to determine that such a mistake has been made, since
most data files carry insufficient information to make them easy to
identify. Consequently, the error presented by the utility may not
obviously identify the cause.
Command Line Errors:
If a command line error occurs, the return code will be set to 9.
***Invalid parameter combination
o The parameters specified on the command line are not compatible with
each other. The return code is set to 9.
o Specify valid parameters for the options you want to use.
/k option is required for conversion to indexed file
o No key definition was given for the index of the file being generated
from a sequential or relative file.
o Specify a key definition.
Data compression out of range
o The integer you specified for data compression is not within the
allowable range.
o Data compression requires an integer in the range 0 through 255.
Data compression specified more than once
o You have specified the option for data compression more than once;
that is, /c:[dn][dn]
o The correct format is /c:[dn][in]
Input file same as output file
o You have given the output file the same name as the input file.
o The output file-name must be different from the input file-name.
Index compression out of range
o The integer you specified for index compression is not within the
allowed range.
o Index compression requires an integer in the range 0 to 7.
Index compression specified more than once
o You have specified the option for index compression more than once;
that is, /c[in][in].
o The correct format is /c:[dn][in].
Invalid command - /n not allowed with Microsoft format file
o You have specified the /n option for a Microsoft format file which
you cannot do unless the Microsoft format file has been converted
into the indexed file format used by this system.
o You must either reenter the command line without the /n option, or
convert the Microsoft format file to the indexed file format used by
this system and enter the command line again.
Invalid command - must specify output file for conversion
o You have omitted an output file-name for a conversion.
o You must specify an output file-name when you want to convert a file
to a different format.
Invalid command line
o The command line contains an error other than those described above.
o Check carefully the syntax, spelling, and spacing in the command line
you are trying to enter.
Invalid compression choice - must be 'd' or 'i'
o The specification of data or index compression was not correct.
o When you want to specify data or index compression, you must specify
the d or i parameters.
Invalid format
o The integer you specified for index file format is not within the
allowable range.
o Index file formats require an integer in the range 0 to 4.
Invalid key length - cannot be zero
o One of the keys you defined has a zero length, which is illegal.
(This may be due to incorrect use of separator characters.)
o Make sure that any keys you define have a valid start character.
Invalid key specification - key not contained in record
o One of the keys, as defined, is not wholly contained in the record.
This is illegal.
o For variable length records, the key must be wholly contained in the
minimum length record.
Invalid key start - cannot be zero
o One of the keys defined has a start character position of zero, which
is illegal. (This may be due to incorrect use of separator
characters.)
o Make sure that any keys you define have a valid start character.
Invalid key structure - '+' expected
o A key part parameter of the /k option is incorrect.
o It must be start character position and length separated by a plus
(+) or L.
Invalid option
o You have specified an invalid option.
o The options you can specify are described earlier in this chapter.
Invalid organization
o The syntax of the /o option is incorrect.
o The only valid organizations you can specify with the /o are s
(sequential), r (relative), or i (indexed).
Invalid organization - 'i' or nothing expected
o The syntax of the /o option is incorrect.
o The only valid characters after the i, s or r are the letter i (when
converting to an indexed file) or a '/' (when another option is
specified).
Invalid organization - must be indexed for index rebuild
o You have tried to rebuild the index of a file whose organization is
sequential or relative.
o Make sure that the file-name you enter for rebuilding is that of an
indexed file. If it is not, the rebuild will fail. See the section
The /o Option earlier in this chapter for further information.
Invalid organization - must be indexed for reorganization
o You have tried to reorganize a file index for a file whose
organization is sequential or relative.
o Make sure that the file-name you enter for reorganization is that of
an indexed file. If it is not, reorganization will fail. See the
section The /o Option earlier in this chapter for further
information.
Invalid record length - cannot be zero
o You have specified that the length of a record is zero. This is
invalid.
o When specifying record lengths, you must specify a length greater
than zero which falls within the limits for record lengths for this
COBOL system. See the appendix File Formats later in this manual for
further details.
Invalid record lengths - maximum must not be less than minimum
o The integers you have used to specify the maximum and minimum lengths
of a record indicate that the maximum length is less than the minimum
length. This is invalid.
o Reenter the maximum or minimum record length again, ensuring that the
maximum length is greater than the minimum length.
Invalid record parameter - '-' expected
o When specifying the record structure of a variable length file, you
have not separated the minimum record length and the maximum record
length with a '-'.
o The correct format is /r:Vminreclen-maxreclen
Invalid record type - 'F' or 'V' expected
o You have entered a record type other than fixed or variable. This is
invalid.
o Reenter the record type using either f (fixed) or v (variable).
Invalid source format
o The format of the /s option is incorrect.
o See the section The /s Option earlier in this chapter for details of
the valid format and parameter to specify with this option.
MS2X specified for non-indexed file
o You have specified that you want to convert a Microsoft COBOL indexed
file when that file is not indexed.
o Make sure that you are using the /s option and the correct parameter.
See the Compatibility Guide for details of this option.
Must have key definition (/k option) with MS2X
o The Microsoft key file is not present.
o You must specify the /k option to enable Rebuild to set up the keys
for this file.
No output file specified for /t to refer to
o You did not specify a name for the output file which was referred to
with the /t option.
o Specify the name of an output file for this option.
No output file specified for data compression
o You did not specify an output file-name for data compression.
o Specify a valid output file-name.
Number expected
o You have specified another character where a number was expected.
o Specify a numeric value for this parameter.
Output file was not specified for indexed output
o No name was given for the output file in conversion to an indexed
file.
o Specify an output file-name.
Parameter file not found
o The parameter file specified on the command line cannot be found.
o Check the file exists, and the specification used on the command line
is correct.
Rebuild Errors:
***Error on input file - bad file structure
o The structure of the input file is not an indexed file in the format
used by this system. The return code is set to 1.
o Ensure that the parameters are correct and that the file is not
corrupt.
***Error on input file - Communications failure
o This error occurs if you have an Fhredir configuration which tells
Rebuild to access files through Fileshare Version 2 (an add-on
product).
o Remove this configuration.
***Error on input file - Disk input output error
o This indicates a hardware fault. You should contact your system
administrator if you receive this error.
***Error on input file - disk space exhausted
o File processing cannot continue because there is insufficient disk
space to do so.
o Ensure that the input file is not corrupt. The output file is closed
and should be usable, if not complete.
***Error on input file - duplicate key - record not written:
o The duplicate key was not written to the output file as this would
have created an invalid duplicate.
***Error on input file - file is not a BTRIEVE indexed file
o The file specified by /s:btrv was not recognized as a Btrieve indexed
file. The return code is set to 1.
o Make sure that the file you specify is a Btrieve indexed file.
***Error on input file - file is not a C-ISAM indexed file
o The file specified by /s:c-isam was not recognized as a C-ISAM
indexed file. The return code is set to 1.
o Make sure that the file you specify is a C-ISAM indexed file.
***Error on input file - file is not an LII indexed file
o The file specified by /s:lii was not recognized as a LEVEL II V2.5
COBOL indexed file. The return code is set to 1.
o Make sure that the file you specify is a LEVEL II V2.5 COBOL indexed
file.
***Error on input file - file is not an MF indexed file
o The file specified by /s:mf was not recognized as an mf indexed file.
The return code is set to 1.
o Make sure that the file you specify is an mf indexed file.
***Error on input file - file is not an MF4 indexed file
o The file specified by /s:mf4 was not recognized as an mf4 indexed
file. The return code is set to 1.
o Make sure that the file you specify is an mf4 indexed file.
***Error on input file - file is not a variable relative file
o The file specified by /o:r is not recognized as a variable relative
file. The return code is set to 1.
o Specify a variable relative file.
***Error on input file - file is not a variable sequential file
o The file specified by /o:s was not recognized as a variable
sequential file. The return code is set to 1.
o Specify a variable sequential file.
***Error on input file - File locked
o The file you specified as your input file is locked by another
process.
o Try again when the file is free to be accessed.
***Error on input file - file must be indexed for rebuild
o You have chosen to rebuild the index of an indexed file that is in
the format used by this COBOL system. The file is in the correct
format but it is not an indexed file. The return code is set to 1.
o Check that you have the correct file and have selected the correct
action.
***Error on input file - file must be indexed for reorganization
o The input file is not an indexed file in the format used by this
system. The return code is set to 1.
o Check that you have the correct file, and that you mean to do a
reorganization.
***Error on input file - file not found
o The input file cannot be found. The return code is set to 1.
o Check that the file-name you entered is correct, and the file does
actually exist. For reorganization or index rebuild ensure that the
index file (.IDX) exists for the given indexed data file.
***Error on input file - illegal filename specified
o A file-name contains an illegal character. This could be any
character that is not part of the permitted character set or it could
be the system-dependent delimiter, which on most systems is the
space.
o Try the file operation again using the correct file-name.
***Error on input file - invalid /x: key-of- reference
o The number specified in the key-of-reference option (/x) exceeds the
number of keys for the given file. The return code is set to 1.
o Check the key required, and try again.
***Error on input file - no record size information
o You have specified the /r option without specifying record lengths.
o Make sure that you specify record lengths when you specify the /r
option. See the section The /r Option earlier in this chapter for
details.
***Error on input file - not MF indexed or variable format
o The input file is not an indexed file, or a variable format file in
the format used by this system. The return code is set to 1.
o Make sure that the file you specify is either an indexed file, or a
variable file whose format is recognized by this COBOL system.
***Error on input file - record size > specified
o The record sizes specified in the /r option do not match those in the
file.
o Correct the /r option and try the operation again.
***Error on input file - status xx
***Error on input file - status 9/yyy
o An error, other than one of the above input file errors, has occurred
while processing the input file. Possible causes are:
- the file does not exist
- a hardware error has occurred opening or reading the file
- the file is corrupt
The status xx is an ANSI'85 file status. If the first byte is a 9,
then the status yyy is a COBOL run-time error number. The output file
is closed, and should be usable, if not complete. The return code is
set to 1.
o See the Error Messages for more details of run-time errors.
***Error on output file - record length < min or > max
o The record length of the output file is less than the minimum or
greater than the maximum length you specified.
o Change the record lengths specified in the /r option.
***Error on output file - status xx
***Error on output file - status 9/yyy
o An error has occurred processing the output file. Possible causes are
that the file cannot be created, or a hardware error has been
encountered on opening or writing the file, or the parameters
specified are incorrect.
The status xx is an ANSI'85 file status. If the first byte is a 9,
then the status yyy is a COBOL run time error number. The return code
is set to 2.
o See the Error Messages for more details of run time errors.
Information Messages
====================
The following information messages are output when Rebuild is processing
a file:
Converting file
o The file you specified is being converted from one format to another.
Rebuild aborted
o You will receive this error followed by one of the errors given in
the section Command Line Errors.
Rebuild successful
o The file you specified has been successfully rebuilt.
Rebuilding file
o The file you specified is being rebuilt.
Rebuilding index
o The index of the file you specified is being rebuilt.
Records processed
o The indicated number of records were processed when the file was
converted, rebuilt or reorganized.
Reorganization successful
o The file you specified has been successfully reorganized.
Reorganizing file
o The file you specified is being reorganized.
Warning Messages
================
Depending on the operation selected, some command line options are
unnecessary. In these cases, the incorrect usage will be indicated, but
the option will be ignored and processing will continue. Note that the
option may be correct, but omission of other information may have caused
Rebuild to select the wrong process. If this is the case, correct the
command line and rerun.
** WARNING ** - Option ignored - /k option not needed for a
reorganization
o A key definition option has been used when an indexed file
reorganization operation has been requested. The option is ignored.
*** WARNING *** - Option ignored - /k option not needed with /n
o A key definition option has been used when an indexed file
reorganization operation has been requested. The option is ignored.
*** WARNING ***. Option ignored - /k option not needed for ms2
conversion.
o A key definition option has been used when you have requested a
Microsoft COBOL V2.2 conversion. This is not required since the key
information is held in the data file of a Microsoft V2.2 indexed
file.
*** WARNING *** - Option ignored - /r option not needed for a
reorganization
o A record structure for a reorganization has been used when only the
/n (information only) option was specified.
*** WARNING *** - Option ignored - /x option not needed for index rebuild
o A key of reference option has been used when an action other than
indexed file reorganization has been selected. The option is ignored.
*** WARNING ***. Option ignored - /x option not needed for ms2
conversion.
o A key of reference option has been used when you have requested a
Microsoft COBOL V2.2 conversion. This is not required since the key
information is held in the data file of a Microsoft V2.2 indexed
file.
=========================================================================
Micro Focus is a registered trademark of Micro Focus Limited.
Micro Focus COBOL, Fileshare, LEVEL II COBOL, and OSX are trademarks of
Micro Focus Limited.
C-ISAM is a trademark of Informix Software Incorporated.
OS/2 is a registered trademark of International Business Machines
Corporation.
Microsoft and XENIX are registered trademarks of Microsoft Corporation.
Windows is a trademark of Microsoft Corporation.
Btrieve is a registered trademark of Novell, Incorporated.
UNIX is a registered trademark of X/Open Company Limited.
=========================================================================
@(#)Vrn/rebuild.1/4.0.00/06Sep95/nrV
Copyright (C) 1993-95 Micro Focus Limited