Advantages And Disadvantages Of Flat File Files

845 Words4 Pages
Question 1: Briefly define and explain a flat file database, giving at least 2 advantages and 2 disadvantages of this type of database. Provide an example of a situation where it would be appropriate to use this type of database.
Answer: FLAT FILE DATABASE
1.1 Definition: Flat file database [1] is the simplest type of database that we can create and manipulate. This database consists of a file, or group of files that contain data in standard and known format that is scanned by a program for requested information. Data modification is usually done by updating an in-memory copy of the data held in the file or files and then writing entire set of data back out to disk. Example of flat file database is: Id First name Last name City Telephone 1 Kunwardeep Singh Patiala 736736374 2 Prabhjeet Kaur Rajpura 473748378 3 Karan Singh Patiala 934374347

Types of flat files formats :
1. Delimited file:
Means files that separate fields with a delimiter character. Comma separated values (CSV) file in which fields are separated from each other by commas is an example of delimited files. Delimited files require much less space than fixed length files. They are better for sequential access but special handling is required so that neither field delimiter or the record delimiter get added into field value.
2. Files that allocate a fixed length to each field:
These files use fixed length records to store data and there is no
Open Document