Lecture 9
Lecture 9
Lecture №9
Lecture’s Outline
The aim of topic: learn how to work with big data or database, explore the database,
can create the table using SQL.
Agenda:
Database
Data Models
Database Management System
Basic terminology in Databases
Database Management Applications
Structured Query Language
Database
A database is a structured collection of records or data. A computer database is a kind of software to
organize the storage of data. Databases help you organize this related information in a logical
fashion for easy access and retrieval. To develop a database, there are several models used such as
Hierarchical model, Network model, Relational model, Object-Oriented model etc. Though
discussing about these models in details is beyond the level of this course unit, for the sake of
completion, some models are briefed below.
Data models
Network model. The network model tends to store records with links to other records. Each record
in the database can have multiple parents, i.e., the relationships among data elements can have a
many to many relationships. So this model is an expansion to the hierarchical structure, allowing
many-to-many relationships in a tree-like structure that allows multiple parents.
The network model provides greater advantage than the hierarchical model in that it promotes
greater flexibility and data accessibility.
Data models
Relational model. The relational model for the database management is a database model based on
relations. The basic data structure of the relational model is a table where information about a
particular entity (say, a student) is represented in columns and rows. The columns enumerate the
various attributes (i.e. characteristics) of an entity (e.g. student name, address, registration number).
The rows (also called records) represent instances of an entity (e.g. specific student).
Data models
A Database Management System (DBMS) is computer housekeeping tasks such as updating data,
deleting obsolete records, and backing up the database.
Obtaining subsets of data software designed for the purpose of managing databases based on a variety
of data models. A DBMS is a complex set of software programs that controls the organization,
storage, management, and retrieval of data in a database. DBMS are categorized according to their
data structures or types, sometime DBMS is also known as a Database Manager. Data management
tasks fall into one of four general categories as given below:
● Entering data into the database.
● There are several advantages in DBMS such as reduced data redundancy and inconsistency,
enhanced data integrity, improved security etc.
Database Management System
Database Table
Object
Field
Record Primary Key
Basic terminology in Databases
The external level defines how each group of end-users sees the organization of data in
the database. A single database can have any number of views at the external level.
The conceptual level unifies the various external views into a compatible global view.
It provides the synthesis of all the external views. It is out of the scope of the various
database end-users, and is rather of interest to database application developers and
database administrators.
The internal level (or physical level) is the internal organization of data inside a
DBMS. It is concerned with cost, performance, scalability and other operational
matters. It deals with storage layout of the data, using storage structures such as indexes
to enhance performance.
Languages
Databases are designed to offer an organized mechanism for storing, managing and
retrieving information.
Server stores many databases
Database stores tables
Tables are constructed by fields
Table saves each data in a row
Fields have type. e.g. integer, string, date, datetime, boolean
Tables: example
Database is MySDU
Tables are students, course, teachers
Fields are name (string/varchar), surname (string/varchar), age (integer)
SQL