Tuesday 23 April 2013

File Organization & Access Method

File Access Method

The way by which information/data can be retrieved. There are two method of file accesss:
  1. Direct Access
  2. Sequential Access
Direct Access
This access method the information/data stored on a device can be accessed randomly and immediately irrespective to the order it was stored. The data with this access method is quicker than sequential access. This is also known as random access method. For example Hard disk, Flash Memory

Sequential Access
This access method the information/data stored on a device is accessed in the exact order in which it was stored. Sequential access methods are seen in older storage devices such as magnetic tape.

File Organization Method

The process that involves how data/information is stored so file access could be as easy and quickly as possible. Three main ways of file organization:
  1. Sequential
  2. Index-Sequential
  3. Random
Sequential file organization
All records are stored in some sort of order (ascending, descending, alphabetical). The order is based on a field in the record. For example a file holding the records of employeeID, date of birth and address. The employee ID is used and records stored is group accordingly (ascending/descending). Can be used with both direct and sequential access.

Index-Sequential organization
The records is stores in some order but there is a second file called the index-file that indicates where exactly certain key points. Can not be used with sequential access method.

Random file organization
The records are stored randomly but each record has its own specific position on the disk (address). With this method no time could be wasted searching for a file. Instead it jumps to the exact position and access the data/information. Can only be used with direct access access method.

2 comments: