answersLogoWhite

0


Best Answer

Enscribe entry-sequenced files are designed for sequential access. They consist of variable-length records that are always appended to the end of the file; as a result, the records in the file are arranged physically in the order in which they were added to the file. The primary key of an entry-sequenced file consists of a record's block number (within the file) and its record number (within the block). When used with FILE_SETPOSITION_, the key is an 8-byte value in which the block number occupies the leftmost 4 bytes of the key and the record number occupies the rightmost 4 bytes. When used with POSITION, the key is a 4-byte value whose format depends on the file's block size, as follows: Block size Number of bits for block Number of bits for record 4096 20 12 2048 21 11 1024 22 10 512 23 9 The record’s address is typically used and manipulated internally by the file system, and there is usually no reason for you to know its value. You can, however, obtain the address of the record just read or written by using the FILE_GETINFOLIST_ system procedure. You use these system procedures to create and access Enscribe entry-sequenced files: • FILE_CREATE_, FILE_CREATELIST_ • FILE_OPEN_, FILE_CLOSE_, AWAITIO[X] • LOCKFILE, UNLOCKFILE, LOCKREC, UNLOCKREC • READ[X], READLOCK[X], READUPDATE[X], READUPDATELOCK[X] • WRITE[X], WRITEUPDATE[X], WRITEUPDATEUNLOCK[X] • FILE_SETKEY, FILE_SAVEPOSITION_, KEYPOSITION, POSITION,FILE_SETPOSITION_ • FILE_GETINFO_, FILE_GETINFOLIST_, FILE_GETINFOLISTBYNAME_,FILE_GETINFOBYNAME_ • SETMODE, CONTROL
After creating the file, there are essentially three operations that you can perform: 1. Use WRITE calls to add new records to the end of the file. 2. Use READ calls to retrieve records from the file. 3. Use FILE_SETLEY or KEYPOSITION calls to specify an alternate-key access path and then use READ calls to retrieve records that contain the specified alternate key value. You can also use the file and record locking system procedures LOCKFILE, UNLOCKFILE, READLOCK, LOCKREC, and UNLOCKREC. Enscribe entry-sequenced files are not designed for random access. If the data records contain unique alternate-key values, however, you can use KEYPOSITION in conjunction with READ or READLOCK to access them randomly. Note. If an error occurs during an attempt to insert a record into an alternate-key file, 0-length records might occur in the primary entry-sequenced file. This can also occur when a transaction aborts that inserted records into an audited entry-sequenced file. The 0-length records are substituted for the inserted records during TMF BACKOUT.

User Avatar

Wiki User

16y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is an entry sequenced files in tandem?
Write your answer...
Submit
Still have questions?
magnify glass
imp