LFADMIN

NAME

lfadmin - administer RMSfile catalog

SYNOPSIS

lfadmin -a [-vx] [-C comment] [-L boolean] [-R boolean] lfile sysname

lfadmin -c [-vx] [-C comment] [-L boolean] [-R booleanblfile directory #rec deffile

lfadmin -d [-vx] lfile

lfadmin -f [-v] lfile

lfadmin -1 [-v] dbname [printfields]

lfadmin -r [-v] lfile [printfields]

lfadmin -u [-vx] [-C comment] [-L boolean] [-R boolean] [-S sysname] lfile

DESCRIPTION

Lfadmin maintains the RMSfile catalog. Lfadmin either adds, updates or deletes a logical RMSfile entry from the RMSfile catalog, or provides catalog information on existing entries.

One of the following flags must be specified to indicate the operation to be performed by lfadmin:

-a Adds an entry for lfile to the RMSfile catalog. An entry in the RMSfile catalog cannot already exist for the logical RMSfile Sysname names the pathname of the RMSfile. This can be an absolute pathname or a pathname relative to the home directory of the database.

The optional flags -C, -L and -R are available to initialize catalog fields. If the -C flag is omitted, the description field is set to null. If the -R flag is omitted, the real file field is set to the boolean value yes. If the -L flag is omitted, the logging status field for lfile is set to the boolean value no.

-c Creates an empty RMSfile in the named directory and adds a logical RMSfile definition for lfile to the RMSfile catalog. If a file exists that matches the logical name in the named directory, or the name is too long for a file entry, a unique name is generated for the RMSfile's pathname. Upon successful completion, the pathname of the logical file is written on standard output. Directory names the directory to contain the new RMSfile. This directory can be an absolute pathname (starting from the root directory) or it can be a name relative to the home directory of the database. #rec specifies the number of records to pre-allocate for the RMS data file. This argument is required but used only when creating a hashed file. Deffile names the RMS definition file to be used in creating the RMSfile.

The optional flags -C, -L and -R are available to initialize catalog fields. If the -C flag is omitted, the description field is set to null. If the -R flag is omitted, the real-file field is set to the boolean value yes. If the -L flag is omitted, the logging status field for lfile is set to the boolean value no.

-d Deletes the logical RMSfile entry for lfile from the RMSfile catalog. The physical RMSfile is not removed from the system.

-f Displays on standard output the absolute pathname of lfile. If the named logical RMSfile is not defined, only a new line character is printed.

-l Displays all logical RMSfiles currently defined for the database dbname. With the -v flag, titles for all selected printfields are displayed. With no printfields selected, the default is the description of each logical RMSfile in addition to its logical name. printfields selects the catalog field information displayed for each logical RMSfile. The printfields available for a logical RMSfile are dbname, lfname, desc, sysname, logged, and real.

-r Displays the catalog field information for one logical RMSfile entry. With the -v flag, titles for all selected printfields are displayed. With no printfields selected, the default is the description of the logical RMSfile lfile and its' logical name. The printfields available for a logical RMSfile are dbname, lfname, desc, sysname, logged, and real.

-u Updates the catalog entry for the existing logical RMSfile lfile. At least one of the optional flags (-C, -L, -R or -S) must be supplied when updating a logical RMSfile entry.

The meanings of the optional flags are:

-v Displays progress information on standard output.

-x Displays on standard output the commands run by lfadmin.

-C comment

Supplies the description of lfile that is stored with the logical RMSfile entry. With the -C flag, comment is required and must be quoted if embedded with blanks, tabs or newlines. If this flag is omitted when adding a logical RMSfile, the description is set to null. If this flag is omitted when the -u flag is specified, the description for the logical RMSfile is unchanged.

-L boolean

Specifies the logging status of lfile. The logging status for an RMSfile indicates whether changes to the RMS data file are to be logged. Boolean is either set to yes, log changes made to the RMS data file, or no, do not log such changes. If the logging status is set to yes, the named database must have defined a log file. The default value for the logging status is no.

-R boolean

Specifies the real file status for an RMSfile. For now, this value must be yes, which is the default value.

-S sysname

Names the system pathname for the logical RMSfile lfile. Sysname can be an absolute pathname (e.q. \cbase\demo\data\mag), or a pathname relative to the home directory of the database (e.q. data\mag).

SEE ALSO

addlf(C-1), dblist(C-1), dbfile(C-1), createlf(C-1), removelf(C-1), makelf(C-1), lfupd(C-1).

NOTES

Lfadmin performs the operations of addlf(C-1), createlf(C-1), dbfile(C-1) and removelf(C-1). The binary program for lfadmin is copied to each of the above programs for backwards compatibility. In addition, for all programs copied from the lfadmin program, each one has a corresponding resource file copied from the lfadmin resource file (\cbase\lib\cbase\resource\lfadmin.r).