Random Access Data and Sequential Access Data

Doctorn
As computers have changed over the years their ability to have larger amounts of RAM (random access memory) and their increasing processing speed has made it less obvious why we ever had a difference in the method of storing data. Essentially the two method of storing data are random access or sequential access.

Sequential access data was typically stored with one segment of data followed directly by the next segment of data. If you had thousands of similar database files they would simply be stored one right next to the other except of course when the next data had to be placed on the next track on the disk. In this type of data storage there was little wasted space as the data filled up areas in a very sequential pattern. This type of storage was particularly useful when a company for example was processing payroll. Since you would want to process a payroll update or check for every employee currently working for the company you would want to be certain to start at the first employee and continue on to the last employee. A sequential file was great for this type of processing but it had a bit of a problem when you had to remove an employee from the database. In most cases you would want to stop future processing which meant that the employee would have to e removed from the database which would then leave a gap in the sequential file. What would happen is that the employee would be removed and the entire file (even if there were thousands of employees) would be rewritten into a temporary file now without the employee/s being deleted, then the entire new file would be rewritten back into the master file but in the new sequential order. This could take quite a bit of time and was typically accomplished late at night or over the weekend. This type of system also absolutely needed a good power backup system because you would not want the system to stop rewriting or processing while in the middle of the process which could cause the loss of data. At the end of such files there was a special code called an EOF (End of File Marker) which identified o the computer that it had reached the end of the file. If power was interrupted it could lose the EOF marker and not be able to find parts of the data or identify the end of the file.

Random Access data was typically placed anywhere on the disk or hard disk that the computer identified as having enough room to store the data. This could waste space because data might be stored with a small area between the data segments that would not be large enough to store a complete file later. It had the advantage of being very quick to remove one or more files or add files because the entire file did not need to be rewritten. The locations of each file were stored in a special much smaller file that was essentially an address of the individual file data location and only that file had to be corrected. The fact that this type of data storage tended to waste space was important in earlier computers but became much less important as the sizes of hard drives greatly increased and computer speeds improved. Today the need for sequential process has been greatly reduced because of the overall advantages of random access storage methods. Random storage has even found a place in large warehouses that can use the computer to locate parts and inventory. In the past a warehouse that stored auto parts might put all the headlights in the same area, all the spark plug types in another area etc. but the computer does not care about this human type of orderly arrangement. The computer can store something in a large warehouse and find it without requiring an area to be assigned to a specific part type.

It is more likely then that when you use a database in the future it will be more likely it will be random access.

Published by Doctorn

A science, computer, and guitar nerd with over 30 years in the field of education with experience teaching at the elementary through college levels.  View profile

To comment, please sign in to your Yahoo! account, or sign up for a new account.