0 votes
70 views
in Compilers & Operating Systems by (user.guest)

1 Answer

0 votes
by (user.guest)
 
Best answer

The different file access methods are as highlighted below:

Sequential Access:

  • This is the most common method.
  • Here the information present in the file is accessed in a sequential fashion, one record after the other.
  • It is a very common approach which is used by editors and compilers usually.
  • The Read and Write operations form the major part of the operations done on a file.
  • A read operation reads the next portion of the file and automatically advances the file pointer, which tracks the I/O location.
  • A write operation appends to the end of the file and advances to the end of the newly written material.

Direct Access:

  • This type of access method provides a speedy access to the file. It provides immediate access to large amount of information.
  • Here a file is made up of logical records that allow programs to read and write.
  • It allows the programs to read and write the records in a rapid manner in no particular (or pre-defined) order.
  • It is based on the disk-model of a file, as a disk allows random access to any block.
  • For direct access, we can view the file as a numbered sequence of blocks or records.
  • This method is usually used in databases.

Indexed access:

  • This method is built on top of Direct access method.
  • Here an index contains the pointers to various blocks of the file.
  • So, to find a record inside a file, we firstly search the index and later use the pointer obtained to access the file directly and find the record we have been searching for.

Please leave a comment below and share with other students in your network if you found this answer helpful. Happy learning!


Related questions

+1 vote
1 answer 1.9k views
+1 vote
1 answer 1.1k views
0 votes
1 answer 98 views
+1 vote
1 answer 1.8k views
+1 vote
1 answer 627 views
+1 vote
1 answer 1.2k views
+1 vote
1 answer 369 views
+1 vote
1 answer 315 views
+1 vote
1 answer 755 views
+1 vote
1 answer 1.9k views
+1 vote
1 answer 3.5k views
+1 vote
1 answer 531 views
0 votes
1 answer 660 views
+1 vote
1 answer 241 views
0 votes
1 answer 893 views
+1 vote
1 answer 118 views
+1 vote
1 answer 86 views
+1 vote
1 answer 132 views
+1 vote
1 answer 102 views
+1 vote
1 answer 309 views
+1 vote
1 answer 274 views
asked Sep 16, 2021 in Computer Networks by anonymous
+1 vote
1 answer 697 views
+1 vote
1 answer 4.5k views
Welcome to CPENTalk.com
Solution-oriented students of computer engineering on one platform to get you that

ONE SOLUTION

...