Table of contents
1.
Introduction
2.
What is Data Independence in DBMS?
3.
Types of Data Independence in DBMS
4.
Logical Data Independence
4.1.
Examples of changes under Logical Data Independence
5.
Physical Data Independence
5.1.
Examples of changes under Physical Data Independence
6.
Difference between Physical and Logical Data Independence
7.
Levels of Database
8.
Importance of Data Independence in DBMS
9.
Frequently Asked Questions
9.1.
Does DBMS provide data independence?
9.2.
What is data dependence and data independence in database? 
9.3.
What is data independence and its types?
9.4.
What is an example of data independence in DBMS?
10.
Conclusion
Last Updated: Mar 27, 2024
Easy

Data Independence in DBMS

Author Ravi Khorwal
0 upvote

Introduction

Data independence in DBMS is a crucial concept for datathe base designers and administrators. It enables changes to be made to the database schema without disrupting the application programs that use it, facilitating easier maintenance and evolution of the system. This article explores data independence in DBMS and the different types of data independence.

Data Independence in DBMS

What is Data Independence in DBMS?

Data Independence is a DBMS feature that enables you to modify the database schema at one level of a database system. It is done without altering the schema at a higher level. Data independence enables you to retain data apart from all applications.

You already know that the primary goal of the three layers of data abstraction is to achieve data independence. If the database evolves and grows over time, it is important that changes at one level do not influence data at other levels of the database. This would reduce the amount of time and money required to change the database.

Types of Data Independence in DBMS

We can modify the data in DBMS with the help of two types of Data Independence. There are two types of data independence:

  1. Logical Data Independence
     
  2. Physical Data Independence
     

Changes to the conceptual schema can be made without altering the application's external view because of logical data independence. Physical data independence allows changes in physical storage to be made without affecting the logical schema, increasing flexibility and adaptability in database management systems (DBMS).

Let’s discuss the types of data independence in detail.

Also See, File System vs DBMS

Logical Data Independence

Logical data is database data, which means that it stores information about how data is managed within the database.

  • The ability to update the conceptual schema without changing data is called logical data independence.
     
  • It is used to distinguish the external level from the conceptual view.
     
  • Any modifications to the conceptual representation of the data will not affect the user’s view of the data.
     
  • Logical data independence arises at the user interface level.

Examples of changes under Logical Data Independence

Let's consider a Database table (relation) and all of the constraints that apply to it.  Logical data independence is a method that decouples itself from the actual data on the disc. If we make modifications to the table format, the data on the disc should not be affected.

If we add a new attribute, entity or relationship is also an example of logical data independence, as there will be no change in the program or application we are working on.

Delete the existing attribute, entity, or relationship that comes under the changes under logical data independence.

Similarly, modification of any entity, attribute, or relationship is a change under it. 

Physical Data Independence

All of the schemas are logical, and the data is saved on the disc in bit format.

The ability to update physical data without affecting the schema or logical data is known as physical data independence.

  • The database's conceptual structure will not be altered if the storage size of the database system server is changed.
     
  • Separating conceptual and internal levels is accomplished by physical data independence.
     
  • Physical data independence occurs at the level of the logical interface.

Examples of changes under Physical Data Independence

If we wish to update or upgrade the storage system itself (for example, by replacing hard drives with SSDs), it should not affect the logical data or schemas.

We can also change the data structure from one to another without any changes in the logical data independence.

Creating a new file will be considered as the changes under physical data independence as there are no changes in the external or logical level layer. 

Similarly, storing the new file in a system is also a change under physical data independence.

Refer this blog to know about Spring Boot Architecture here.

Difference between Physical and Logical Data Independence

Let's see the difference between physical and logical data independence.

Physical Data Independence Logical Data Independence
It primarily concerns the manner in which data is saved within the system. It largely focused on the structure or the changing definition of the data.
Retrieval of physical data independence is easy. Retrieval of logical data independence is difficult.
We don’t have to change the application level if we make any changes at the physical level. We have to make changes at the application level for the change at the logical level.
It may or may not be necessary to make internal changes to the structure in order to enhance its performance. Any time the logical structure of the database needs to be modified, the changes made at the logical level are crucial.
It is concerned with the internal schema. It is concerned with the conceptual schema.

Levels of Database

A database follows three-level architecture which is discussed below:

  • Physical Level: This is the bottom level of the three-tiered architecture. It is often referred to as the interior level. The physical level specifies how data is stored in the database. At the most basic level, this data is saved in the form of bits in external hard drives, and at a slightly higher level, it can be claimed that the data is stored in files and folders
     
  • Conceptual Level: The conceptual level is greater than the physical level. It is often referred to as the logical level. It explains how the database appears conceptually to users, as well as the relationships between distinct data tables. The conceptual level is unconcerned about how the data in the database is stored
     
  • External Level: This is the highest level of the three-tier architecture, and it is the one closest to the user. It is often referred to as the view level. The external level only displays to users the relevant database content in the form of views and hides the rest of the data. As a result, various users can see the information in different ways depending on their needs

Importance of Data Independence in DBMS

  • It encourages you to improve the information's quality
     
  • Database disjointness is infinitely reduced
     
  • In application programs, you do not need to change the information structure
     
  • It allows designers to focus on the overall structure of the Database rather than obsessing over the interior usage
     
  • Making effective physical modifications is predicted to boost the framework's exhibition

Frequently Asked Questions

Does DBMS provide data independence?

Data independence in DBMS is a crucial concept for database designers and administrators. It enables changes to be made to the database schema without disrupting the application programs that use it, facilitating easier maintenance and evolution of the system.

What is data dependence and data independence in database? 

Data dependence refers to the program's level of exposure to adjustments made to that external source while Data Independence is a DBMS feature that enables you to modify the database schema at one level of a database system.

What is data independence and its types?

Data independence refers to the ability to change the database schema without impacting the applications using it. There are basically two types of data independence: physical data independence and logical data independence.

What is an example of data independence in DBMS?

An example of data independence in DBMS is when a database administrator modifies the physical storage structure of the database, such as moving data to a different disk or changing the indexing strategy, without affecting the application programs that use the database.

Conclusion

Cheers if you reached here!! In this blog, we learned about Data Independence in Databases. We have covered the basic idea of Data Independence in DBMS and also saw the various types of data independence. We also witnessed the ACID properties and their uses with examples.
Recommended Articles -

You can also consider our DBMS Course to give your career an edge over others. Good luck with your preparation!!

Live masterclass