Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
5 views11 pages

Dbms Notes 1.1

A Database Management System (DBMS) is software designed to efficiently store, manage, and retrieve data, addressing issues found in traditional file-based systems such as data redundancy, inconsistency, and poor security. DBMS applications span various fields including banking, airlines, and online shopping, providing benefits like reduced redundancy, improved data access, and enhanced security. The document also explains the concepts of schema and instance, highlighting the structure of databases and the actual data stored at any given time.

Uploaded by

Siddharth
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views11 pages

Dbms Notes 1.1

A Database Management System (DBMS) is software designed to efficiently store, manage, and retrieve data, addressing issues found in traditional file-based systems such as data redundancy, inconsistency, and poor security. DBMS applications span various fields including banking, airlines, and online shopping, providing benefits like reduced redundancy, improved data access, and enhanced security. The document also explains the concepts of schema and instance, highlighting the structure of databases and the actual data stored at any given time.

Uploaded by

Siddharth
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 11

Introduction to DBMS

• DBMS (Database Management System) is software that helps to store,


manage, and retrieve data efficiently.

• It eliminates the problems of traditional file-based systems (like redundancy and


inconsistency).
Database-System Applications

DBMS is used in almost every field today. Some examples:

• Banking – To manage accounts, transactions.

• Airlines – Reservation systems and schedules.

• Universities – Student records, course registration.

• Telecommunication – Call records, billing.

• Online Shopping – Inventory, customer data.

• Social Media – User profiles, messages.

Problems with Traditional File-Based Approach

In olden days, data was stored in separate files (like text files, Excel sheets, etc.), and
each application had its own files.

This caused many problems:

1. Data Redundancy (Duplicate Data)

Problem: Same data is stored multiple times in different files.

Example:
Student's name and roll number stored in:

• Exam file

• Library file

• Hostel file

Wastes space and effort.

2. Data Inconsistency (Mismatch of Data)

Problem: Same data shows different values in different files.

Example:
You update your phone number in the library file, but it's still old in the exam file.

Creates confusion, errors, and unreliable reports.


3. No Data Sharing

Problem: Data stored in one file cannot be easily accessed by other


applications.

Example:
The library software can't access student marks from the exam file directly.

Leads to duplication of effort and isolated systems.

4. Difficult to Search and Access Data

Problem: Searching for specific data (like all students above age 18)
requires manual effort or writing custom code.

Example:
You need to scan the whole file or write a program — no simple query like in
DBMS.

5. Poor Data Security

Problem: File systems have no proper access control.

Example:
Anyone who has the file can view or change all the data — no restriction
like “read-only” or “admin only.”

6. No Backup and Recovery

Problem: If a file gets deleted or corrupted, data is lost forever.

Example:
Power failure during editing may destroy the file — and there’s no way to
recover.
7. Integrity Problems

Problem: No rules to ensure data is correct or valid.

Example:
You can enter age = -10 or phone number = "abc123" — file systems don't
check data correctness.

8. Concurrency Issues

Problem: If two people try to access/edit the same file at the same time, it
may cause data loss or overwrite.

Example:
Two staff members update the same student record → one of the changes
gets lost.

Traditional file-based systems are simple but not suitable for


large, multi-user, secure, and reliable data management.
That’s why we need a Database Management System (DBMS).
Purpose of Database Systems (DBMS)
A Database Management System (DBMS) is used to store, manage, and retrieve data
easily and safely. It solves the problems that existed in traditional file-based systems.

1. Reduce Data Redundancy

Redundancy means storing the same data again and again.

• In file systems, data was repeated in many files.

• In DBMS, data is stored only once, and shared when needed.

Example:
In a college system, the student’s name and ID were saved in multiple files —
attendance, marks, library, etc.
Now with a database, it's saved once, and all departments access the same data.

2. Avoid Data Inconsistency

Inconsistency happens when the same data is different in different places.

• DBMS keeps data consistent and updated across all users.

• Any change in one place is reflected everywhere.

Example:
If you update your mobile number in the student portal, it automatically updates in the
library and exam system too.
3. Efficient Data Access

• DBMS provides quick and easy access to data using queries.

• We can search, filter, and get data in seconds.

Example:
Want to find all students who scored above 90? Just write a small query and get results
instantly.

4. Data Sharing

• DBMS allows multiple users to use the same data at the same time.

• Everyone gets a proper view based on their role.

Example:
A teacher can see marks, a librarian can see book records, and a student can see only
their profile.

5. Data Security

• Only authorized users can access or edit data.

• DBMS allows setting permissions for each user.

Example:
Students can’t change marks, but teachers and admins can.

6. Backup and Recovery

• DBMS takes regular backups of data.

• In case of system failure, we can restore the data safely.

Example:
If a college server crashes, no need to worry — data can be recovered from backup.

7. Data Integrity

• Ensures that data entered is correct and accurate.

• Uses rules and constraints like “roll number should be unique.”


Example:
You can’t enter "age = -10" or "roll number = ABC123" if it expects numbers only.

8. Concurrent Access and Multi-User Support

• Many users can access and use the database simultaneously without
problems.

• DBMS manages locking and transactions to avoid errors.

Example:
Hundreds of students can register for classes at the same time without crashing the
system.

9. Enforced Standards

• DBMS ensures that data is stored in a standard format.

• Helps in better understanding and organization.

Example:
Dates are stored as YYYY-MM-DD, phone numbers in the correct format.

10. Improved Decision Making

• Clean, organized, and accurate data helps in making better decisions.

• Reports and summaries can be generated easily.

Example:
A principal can view student performance trends and decide how to improve results.
View of Data
➤ Instances and Schemas

• Instance: The actual data stored in a database at a given time.


Like the current content in a table.

• Schema: The structure or design of the database.


Like the blueprint of a table (columns, data types).

What is a Schema?
A Schema is the structure or design of a database.
It defines what tables exist, what columns they have, and what types of data are
stored.

Think of schema as the blueprint or format of a table, just like a form you create
to collect data.

Example:

Let’s say we are creating a table to store student details.

CREATE TABLE Student (

StudentID INT,

Name VARCHAR(50),

Age INT

);

Here, the schema defines:

• Table name: Student

• Columns:

o StudentID (integer)

o Name (text up to 50 characters)

o Age (integer)

This schema will remain the same whether there are 0 records or 1 million records.
What is an Instance?
An Instance of a database is the actual data stored in the database at a specific point
in time.

Think of instance as the current content inside your table — the rows of data.

Example using the above Student schema:

Let’s say the current data in the table is:

StudentID Name Age

101 Alice 18

102 Bob 19

103 Charlie 20

This is the current instance of the table.


If you delete one student or add a new one, the instance changes, but the schema
remains the same.

Schema = What kind of data we store (design)


Instance = What data we have stored right now (actual data)
Next Topic : Data Abstraction, Data Independence

You might also like