ERASE Verb - Erase File

Syntax

ERASE fileid{,MODE=string}{,ERR=lineref}

Description

For BBj-specific information, see the ERASE Verb - BBj.

The ERASE verb causes PRO/5 to locate the specified file and remove it from the directory.

Parameter

Description

fileid

ID of the file to be removed.

MODE=string

On some systems, it may be necessary to use the MODE= option to select the file to be removed. For example, under the UNIX operating system, the C-ISAM file type must be selected in the ERASE by using the "CISAM" string in the MODE= option.

ERR=lineref

Branch to be taken if an error occurs during execution.

On some systems the file may still exist by another name. When the last directory entry for that file is removed, PRO/5 releases the disk space used by that file. Users cannot access the file again. See the Files section in the User's Reference Guide for additional information.

On most systems, if the file is in use (OPEN) when the ERASE is attempted, PRO/5 returns an error.

Examples

>ERASE "TEST.BBX"
1000 ERASE A$,ERR=9500

See Also

DELETE Verb

Modifying Programs to Access the Data Server

Verbs - Alphabetical Listing