Moving the record pointer: –

Moving the record pointer: – The seek statement is used to move record pointer in a random-access file. This statement can be used to move record pointer at any one record position. Syntax of the seek statement is –

                Seek <File Number>, <Record Position>

If the next put or get statement does not specified a record number, the record affected will be the one positioned by calling seek. For example –

                Seek 1,5

The record pointer will have positioned at fifth record from where record to be write or read by the put or get statement respectively.

Advertisements

Comments are closed.

Create a website or blog at WordPress.com

Up ↑

%d bloggers like this: