Just Fun with DBMS


Data:
Data is a collection of raw, unorganized facts like text, observations, numbers, and symbols etc. It doesn't have any meaning unless processed.
Information:
When unorganised data processed, organized that provides meaning and context, making it useful for decision-making.
Diagram:
Database:
Database is software that stores structured data electronically in the system in a way that can be easily accessed, managed & updated. To make real use of data, we need DBMS.
DBMS:
It is software that manages the storage and retrieval of data in a database & provides a set of tools and programs to add, access, update & delete data.
e.g.: Relationship between DBMS and API: The DBMS manages the database and provides an interface (often through SQL or other query languages) for applications to interact with the data. An API acts as a middle layer that facilitates this interaction, allowing applications to request data from the DBMS or send data to be stored in the database without needing to know the specifics of how the database is managed.
So, the DBMS handles the actual data management, while the API handles the communication between the application and the DBMS.
Schema:
A database schema is considered the “blueprint” of a database which describes how the data is organized, the relationships between different parts of the data, and the constraints on the data.
It refers to the structure or organization of the database.
Database State:
The situation where the collection of data or information stored in the database at a particular moment in time is referred to as the database state. This state represents the current contents of the database, including all the values in the tables at that moment. Just like the value of a variable changes over time, the state of the database can grow, shrink, or alter as data is inserted, updated, or deleted. However, the underlying structure of the database, such as the schema, remains unchanged unless explicitly modified.
Database Instance:
A database instance is the active, running environment that manages the database(s). It consists of database management system (DBMS) software, memory structures, and background processes that interact with the stored data.
When you start the database server, an instance is created, which allows users and applications to interact with the databases it manages.
Data Abstraction:
DBMS provides users with an abstract view of the data, which means the system hides certain details of how the data is stored and maintained.
It provides a different view and helps in achieving data independence which is used to enhance the security of data.
To simplify user interaction with the system, abstraction is applied through 3 levels of abstraction.
Physical / Internal Level:
The is the lowest level of abstraction in a database system. It describes how the data is actually stored in the database. This includes details about the data storage methods, file structures, indexing, and the way data is organized on storage devices (like hard drives or SSDs).
Logical / Conceptual Level:
This level describes the design of a database, specifying what data is stored and the relationships that exist among those data. It defines the schema objects such as tables, views, indexes, and relationships, along with the integrity constraints that ensure data accuracy and consistency.
This level is independent of physical storage details and focuses on the structure and organization of the data within the database.
View / External Level:
The highest level of abstraction aims to simplify users' interaction with the DB by providing different views to different end-users. At views also provide a security mechanism to prevent users from accessing certain parts of the database without needing to understand its complexity.
Diagram:
Data Independence:
It is defined as the property of DBMS that has the capability to change the schema at one level of the DB without changing or affecting the schema at other levels.
- Physical Data Independence:
The ability to change the physical schema (storage structure) without affecting the logical schema or the applications that use the database.
Explanation: Physical schema changes how data is stored on the disk (like how files are organized or indexed) without affecting the overall structure of the database or how applications use the data. Physical data independence ensures that these changes do not impact the logical structure of the database or the applications that access the data. For example, you might improve performance by changing storage methods, but users and applications will still see and interact with the data the same way.
- Logical Data Independence:
The capacity to change the logical schema without changing the external schema or application programs.
Explanation: Logical schema changes involve altering the structure of the database, such as adding or removing tables or changing relationships. Logical data independence ensures that such changes do not affect how users interact with the data through their views or how applications access the data. For example, you can add new columns or tables without requiring changes to the applications that use the database.
Subscribe to my newsletter
Read articles from MRUTYUNJAYA SAHOO directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by

MRUTYUNJAYA SAHOO
MRUTYUNJAYA SAHOO
Passionate about programming, I see its impact everywhere in the modern world. I believe that I will be a great addition to the team and organization. Making a positive impact through hands-on experience and continuous learning.