How is the databased approach different from the file based approach?
Or
Explain the difference between a file oriented system and a database oriented system.
Or
Differentiate between database approach v/s traditional file accessing approach.
There are a number of characteristics to distinguish the database approach from the traditional approach of programming with files. In traditional file processing. each user defines and implements the files needed for a specific application as part of programming the application. For example, one user, the grade reporting office, may keep a file on students and their grades. Programs to print a student transcript and enter new grades into the file are implemented. A second user, the accounting office, may keep track of student’s fees and their payments. Although both users are interested in data about students, each user has to maintain separate files and programs to manipulate these files because each user requires some data not available from the other user’ files. his redundancy in defining and storing data causes wasted storage space and redundant effort to maintain common data up-to-date. In the database approach, a single repository of data is maintained that is defined once and then is accessed by various users.
The main characteristics of the database approach versus the file – processing approach are as follows:-
(i) Self-describing Nature of a Database System:- The database system contains not only the database itself but also a complete definition or description of the database structure and constraints. This definition is stored in the system, catalog, which contains information such as the structure of each file, the type and storage format of each data item and various constraints on the data. The information stored in the catalog is meta-data and it describes the structure of the primary database.
In traditional file processing, data definition is the part of the application programs themselves. Hence, these programs are constrained to work with only one specific database, whose structure is declared in the application programs. Whereas file-processing software can access only specific databases. DBMS software can access diverse databases by extracting the data definitions from the catalog and then using these definitions.
(ii) Insulation between Programs and Data, and Data Abstraction:- In traditional file processing, the structure data files is embedded in the access programs, so any changes to the structure of a file may require changing all programs that access this file. By contrast, DBMS access programs do not require such changes. The structure of data files is stored in the DBMS catalog separately from the access programs. This property is called program-data independence. The characteristic that allows program-data independence and program operation independence is called data abstraction.
(iii) Multiple Views of the Data:- A database has many users, each of whom may require a different perspective or view of the database. A view may be a subset of the database or it may contain virtual data that is derived from the database files but is not explicitly stored. Some users do not need to be aware of whether the data they refer to is stored or derived. A multiuser DBMS having variety of applications must provide facilities for defining multiple views.
(iv) Sharing of Data and Multiuser Transaction Processing:- A multiuser DBMS must allow multiple users to access the database at the same time. This is essential if data for multiple applications is to be integrated and maintained in a single database. The DBMS must include concurrency control software to ensure that several users trying to update the same data do so in a controlled manner so that the result of the updates is correct.