Database Management System: Lec - 1: Basic Database Concepts
Database Management System: Lec - 1: Basic Database Concepts
System
Reference Books:
⸙ Fundamentals Of Database System, 7Th Edn by Elmasri
Ramez And Navathe Shamkant | 2016
⸙Assignments/projects 20%
⸙Quizzes 10%
Evaluation Criteria: ⸙Mid-Term 20%
⸙Final 50%
• We consider a database to be a collection of
related data and a database management
system (DBMS) to be the software that
manages and controls access to the database.
Use of
Booking a vacation with a travel agent
Database in
Our Daily Using the local library
Lives
Using the Internet
Studying at College
• Conventionally, the data were stored and processed
using traditional file processing systems.
Traditional
File-based
Systems
However, the manual filing system
breaks down when we have to
process the information in the files.
• For example, a typical real estate agent’s office might have a separate file for each
property for sale or rent, each potential buyer and renter, and each member of staff.
Consider the effort that would be required to answer the following questions:
• What three-bedroom properties do you have for sale with an acre of land and a garage?
• What apartments do you have for rent within three miles of downtown?
• What is the average rent for a two-bedroom apartment?
• What is the annual total for staff salaries?
• How does last month’s net income compare with the projected figure for this month?
Example of a Traditional Database
Application
Suppose we are building a system
to store the information about:
• students
• courses
• professors
• who takes what, who teaches what
11
Can we do it without a DBMS ?
Sure we can! Start by storing the data in files:
12
Doing it without a DBMS...
• Enroll “Mary Johnson” in “CSE444”:
Read
Read ‘students.txt’
‘students.txt’
Read
Read ‘courses.txt’
‘courses.txt’
Find&update
Find&update the
the record
record “Mary
“Mary Johnson”
Johnson”
Find&update
Find&update the
the record
record “CSE444”
“CSE444”
Write
Write “students.txt”
“students.txt”
Write
Write “courses.txt”
“courses.txt”
13
Problems without a DBMS...
• System crashes: Read ‘students.txt’
Read ‘students.txt’
Read
Read‘courses.txt’
‘courses.txt’
Find&update
Find&updatethetherecord
record“Mary
“MaryJohnson”
Johnson”
CRASH !
Find&update the record “CSE444”
Find&update the record “CSE444”
Write
Write“students.txt”
“students.txt”
Write
Write“courses.txt”
“courses.txt”
14
When we analyze the information needs
of an organization, we attempt to
identify entities, attributes, and
relationships.
• The role of the DBA is more technically oriented than the role of the DA,
requiring detailed knowledge of the target DBMS.
• In large database design projects, we can
distinguish between two types of designer:
logical database designers and physical
database designers.
2. Database
Designers • The logical database designer is concerned
with identifying the data (that is, the entities and
attributes), the relationships between the data,
and the constraints on the data that is to be
stored in the database.
• The physical database designer decides how the logical database design is to be
physically realized. This involves:
• mapping the logical database design into a set of tables and integrity constraints;
• selecting specific storage structures and access methods for the data to achieve
good performance;
Improved
Data Constraints may apply to data items within a single record
or to relationships between records.
Integrity
For example, an integrity constraint could state that the
salary of a staff’s member cannot be greater than $40,000
or that the branch number contained in a staff record,
representing the branch where the member of staff works,
must correspond to an existing branch office.
• Database security is the protection of the database
from unauthorized users.
• This security may take the form of user names and
passwords to identify people authorized to use the
database.