IB Statements/clearfile
From CometWiki
(New page: CLEARFILE statement Syntax: CLEARFILE (lun) Discussion: The CLEARFILE statement clears all data from an open Comet data file. The lun parameter is the numeric value that is assigned ...) |
|||
Line 1: | Line 1: | ||
- | CLEARFILE statement | + | '''CLEARFILE statement''' |
- | Syntax: CLEARFILE (lun) | + | |
- | Discussion: The CLEARFILE statement clears all data from an open Comet data file. | + | '''Syntax:''' CLEARFILE (lun) |
+ | |||
+ | '''Discussion:''' The CLEARFILE statement clears all data from an open Comet data file. | ||
+ | |||
The lun parameter is the numeric value that is assigned to the previously opened data file. The lun may be a numeric constant, numeric variable, or a symbolic constant. Its value may be from 0 through 49. | The lun parameter is the numeric value that is assigned to the previously opened data file. The lun may be a numeric constant, numeric variable, or a symbolic constant. Its value may be from 0 through 49. | ||
The CLEARFILE statement does not remove the data file entry from the Comet directory (like the ERASE statement does); it just clears all of the data records from the file. | The CLEARFILE statement does not remove the data file entry from the Comet directory (like the ERASE statement does); it just clears all of the data records from the file. | ||
- | History: This feature was added to CometServe32 and CometServeNLM Version 2.59. | + | '''History:''' This feature was added to CometServe32 and CometServeNLM Version 2.59. |
+ | |||
Example: OPEN (20) "WORKFILE",DIR="DSK" | Example: OPEN (20) "WORKFILE",DIR="DSK" | ||
. | . |
Revision as of 09:24, 20 May 2009
CLEARFILE statement
Syntax: CLEARFILE (lun)
Discussion: The CLEARFILE statement clears all data from an open Comet data file.
The lun parameter is the numeric value that is assigned to the previously opened data file. The lun may be a numeric constant, numeric variable, or a symbolic constant. Its value may be from 0 through 49.
The CLEARFILE statement does not remove the data file entry from the Comet directory (like the ERASE statement does); it just clears all of the data records from the file.
History: This feature was added to CometServe32 and CometServeNLM Version 2.59.
Example: OPEN (20) "WORKFILE",DIR="DSK" . . . CLEARFILE (20) . . . CLOSE (20)
This example shows a data file named WORKFILE,DSK being opened on lun 20. The CLEARFILE statement clears all of the data from this file. At the end of the code segment, the file is closed.