Introduction

Language Structure

IB Statements

File System

Comet 32 Runtime

Index

File I/O Operations

The Internet Basic language provides over twenty statements related to file input and output operations. These are explained in detail in the Procedure Division documentation.

Below is a brief summary of the most common file operations. Note that some of these operations may not be performed simultaneously by multiple users, or actions taken by one user could affect file operations attempted by another.

At the highest level, Internet Basic file operations include statements to open, close, create, erase, rename, lock, and unlock a file, including:

CREATE
ERASE
RENAME
OPEN
CLOSE
LOCK
UNLOCK

Note: Starting with Comet version 504.211, whenever a filename is referenced in a Comet statement (in the OPEN, CREATE, and RENAME statements, for example), the system converts the filename to upper case before making the call. This change was made in response to some case-sensitive problems encountered on several Windows NT installations.

Once a data file is created and opened, normal I/O operations may proceed. Internet Basic provides statements for reading records, writing records, reading and locking records, deleting records, etc. These include:

WRITE
READ
EXTRACT
INQUIRE
DELETE

Internet Basic also provides statements for inserting, rewriting, and updating data records, including:

UPDATE
INSERT
REWRITE

In addition to these direct input/output statements, Internet Basic provides several file functions, including:

FIRST
LAST
KEY
POSITION
PREV
RECNUM