Notes 01 - Introduction
Notes 01 - Introduction
Yousef M. Elmehdwi
Department of Computer Science
1 / 32
Core Terminology Review
Data
Data refers to any piece of information that holds value and is worth
keeping.
It’s often stored in electronic form and can range from numbers and text
to images and videos.
Database
organized collection of interrelated data that models some aspect of the
real-world.
Query
operation that retrieves specific data from a database based on certain
criteria or conditions.
queries allow users to extract relevant information.
Relation
refers to the organization of data into a two-dimensional table, where rows
(tuples) represent basic entities or facts of some sort, and columns
(attributes) represent properties of those entities.
Schema
a description of the structure of the data in a database, often called
“metadata”
it’s like a blueprint that outlines how the data is organized, what types of
data are stored, and how they are related.
2 / 32
Database Management System (DBMS)
3 / 32
Advanced Database Organization?
=Database Implementation
=How to implement a database system
and have fun doing it ;-)
4 / 32
What do you want from a DBMS?
5 / 32
Isn’t Implementing a Database System Simple?
6 / 32
Introduction the Megatron 3000
Database Management System
7 / 32
Megatron 3000 Implementation Details
Smith # 123 # CS
Jonson # 522 # EE
..
.
8 / 32
Megatron 3000 Implementation Details
9 / 32
Megatron 3000 Implementation Details
10 / 32
Megatron 3000 Sample Sessions
11 / 32
Megatron 3000 Sample Sessions
A # ends a query
12 / 32
Megatron 3000 Sample Sessions
13 / 32
Megatron 3000 Sample Sessions
14 / 32
How Megatron 3000 Executes Queries
To execute
15 / 32
Megatron 3000 Query Execution
To execute
16 / 32
Megatron 3000 Query Execution
17 / 32
What’s wrong with Megatron 3000 DBMS?
18 / 32
What’s wrong with Megatron 3000 DBMS?
19 / 32
What’s wrong with Megatron 3000 DBMS?
20 / 32
What’s wrong with Megatron 3000 DBMS?
Much better if use index to select tuples that satisfy condition (Do select
using S.B >1000 first)
More efficient join (sort both relations on A and merge)
21 / 32
What’s wrong with Megatron 3000 DBMS?
No buffer manager
There is no way for useful data to be buffered in main memory; all data
comes off the disk, all the time
e.g., need caching.
22 / 32
What’s wrong with Megatron 3000 DBMS?
No concurrency control
Several users can modify a file at the same time with unpredictable results.
23 / 32
What’s wrong with Megatron 3000 DBMS?
No reliability
e.g., in case of error/crash, say, power failure or leave operations half done
Can lose data
24 / 32
What’s wrong with Megatron 3000 DBMS?
No security
e.g., file system security is coarse
Unable to restrict access, say, to some fields of a relation and not others
25 / 32
What’s wrong with Megatron 3000 DBMS?
26 / 32
What’s wrong with Megatron 3000 DBMS?
27 / 32
What’s wrong with Megatron 3000 DBMS?
No GUI
28 / 32
This Course
29 / 32
Reading assignment
Refresh your memory about basics of the relational model and SQL
from your earlier course notes
from some textbook
http://cs.iit.edu/~cs425/schedule.html
30 / 32
Reading
31 / 32
Next
Notes 2: Hardware
32 / 32