Welcome back! In our last lesson, we defined what a database and a Database Management System (DBMS) are, establishing that a DBMS is the software used to manage data efficiently. We also touched on the idea that a DBMS is designed to solve problems inherent in more traditional data storage methods.
Today, we're going to explore those traditional methods, known as file-based systems. This lesson directly addresses the limitations of that approach and highlights the significant advantages of using a modern database system. By the end of our session, you'll be able to clearly distinguish between these two approaches and articulate why the database model has become the standard for nearly all modern applications.
1. The Traditional Approach: File-Based Systems
Before the widespread adoption of DBMS, organizations managed their data using what we call file-based or file-processing systems. In this model, data is stored in a collection of separate, flat files (like text files, spreadsheets, or binary files), and each application or department is responsible for managing its own set of files.
Given your background in IT, you can think of this as a decentralized approach where there is no central "manager" for the data. Each program interacts directly with the files it needs.
The image below illustrates this concept. You can see how different departments (Personnel, Sales, Accounting) maintain their own, often overlapping, sets of data files.

This decentralized structure seems simple at first, but it introduces a host of serious problems, especially as systems grow in scale and complexity.
2. The Problems with File-Based Systems
The limitations of file-based systems are the primary motivation for developing and using a DBMS. The following video provides a comprehensive overview of the seven major drawbacks. As you watch, pay close attention to the examples provided for each point, as they make the abstract problems very concrete.
File System vs. Database Management System
This video from Neso Academy, titled "File System vs. Database Management System," systematically details the disadvantages of the file system approach.
Watch the video from the main comparison. The presenter will walk through seven key problems that arise when using file systems for data management.
Let's summarize the critical issues discussed in the video. These are the core reasons why the database approach is superior.
- Data Redundancy and Inconsistency: This is perhaps the biggest issue. Because data is duplicated across different files, the same piece of information (like a customer's address) can exist in multiple places. If it's updated in one file but not another, the data becomes inconsistent, leading to confusion and errors. This also wastes storage space.
- Difficulty in Accessing Data: Retrieving data to answer specific questions is difficult. If a manager needs a report that combines data from different files, a programmer has to write a new application specifically for that task. There's no general-purpose query language to easily ask questions of the data.
- Data Isolation: Data is scattered across various files, which may also be in different formats. This makes it challenging to write new applications that need to retrieve data from multiple, disparate sources.
- Integrity Problems: Data integrity refers to maintaining the accuracy and consistency of data. It's difficult to enforce constraints in a file system. For example, how do you ensure that an employee's salary is always a positive number, or that a department code entered into a record actually exists? This logic has to be manually coded into every application that uses the data.
- Atomicity Problems: Many operations require several steps. Consider a bank transfer: money must be debited from one account and credited to another. This is an "all or nothing" operation. If the system crashes after the debit but before the credit, the data is left in an inconsistent state. Guaranteeing atomicity is very difficult in file systems.
- Concurrent Access Anomalies: When multiple users try to access and update the same data simultaneously, the results can be incorrect. The video's example of two clerks withdrawing money from the same account is a classic illustration. File systems generally have poor mechanisms for managing concurrent access.
- Security Problems: It is hard to enforce complex security policies. While an operating system can protect entire files, it's not designed to restrict access to specific parts of a file. For example, how do you allow a user to see an employee's name and department, but not their salary? This kind of granular, role-based security is very difficult to implement.
3. The Solution: Advantages of the Database Approach
A Database Management System (DBMS) is specifically designed to solve all of the problems we just discussed. By centralizing data management, a DBMS provides a robust, secure, and efficient solution.
The most effective way to understand the advantages of a DBMS is to directly compare it to a file system. The following reading provides an excellent, detailed comparison table.
File System Vs. DBMS: Key Differences and Usages Explained
This article from Unstop offers a clear, feature-by-feature comparison of file systems and DBMS.
Focus your attention on the section "A Table of Differences Between File Systems and DBMS." Study the table carefully. For each feature (like Data Redundancy, Data Integrity, Security), notice how the DBMS column directly addresses the weaknesses of the File System column.
As the table shows, the database approach offers clear advantages:
- Controlled Redundancy & Enforced Consistency: Through a technique called normalization (which we will study in detail later), a DBMS minimizes data duplication. Because data is stored in one central place, updates are applied consistently for all users.
- High Data Integrity: A DBMS allows you to define and enforce integrity constraints directly on the database. This ensures that only valid data is stored, regardless of which application is trying to add it.
- Powerful & Easy Data Access: DBMSs provide powerful query languages, with SQL (Structured Query Language) being the most common. This allows users to retrieve complex information without needing a custom program written for every question.
- Advanced Security: A DBMS has sophisticated security and authorization mechanisms, allowing administrators to control precisely who can see and modify which pieces of data.
- Concurrency Control: A DBMS includes built-in mechanisms to manage simultaneous access, ensuring that transactions do not interfere with each other and corrupt the data.
- Backup and Recovery: Professional DBMSs provide automated tools for backing up data and recovering it in case of a system failure, ensuring data is not lost.
- Data Independence: The DBMS separates the logical structure of the data from its physical storage. This means you can change how the data is stored on disk without having to rewrite the applications that use it.
Conclusion
In this lesson, we contrasted the traditional file-based approach to data management with the modern database approach. We identified the significant drawbacks of using scattered, independent files and saw how a DBMS is specifically engineered to overcome them.
Here are the main takeaways:
- File-based systems store data in separate files, managed by individual applications. This approach is simple for small-scale use but suffers from major issues like data redundancy, inconsistency, poor security, and difficulty in accessing data.
- A Database Management System (DBMS) offers a centralized approach, providing robust solutions to the problems of file systems.
- The key advantages of the database approach include controlled redundancy, high data integrity, enhanced security, built-in concurrency control, and powerful data access through query languages.
Now that you have a firm grasp of why we use databases, we are ready to move on. In our next lesson, we will begin exploring how data is organized within a modern database. We will introduce the relational data model, the most widely used model today, and learn how data is structured into tables, rows (tuples), and columns (attributes). This is the first step toward designing databases yourself.