ID Expression

An ID expression is a string expression that evaluates to an item-ID, for use in all types of read and write statements.

Example(s)

In this example, the ID expression is "12345".

read invoice.item from invoice.file,"12345" else...

In this example, the value entered into the variable ID is used as the ID expression:

input ID

read record from file,ID else...

Both the literal string 'last-ID' and the arithmetic expression last-ID+1 are ID expressions.

read last-ID from ctlfile,'last-ID' then

write item on datafile,last-ID+1

write last-ID+1 on ctlfile,'last-ID'

end

See Also

delete Statement, matread Statement, matwrite Statement, read Statement, readv Statement, release Statement, write Statement, writev Statement, writevu Statement