01-EN-Structured Query Language
01-EN-Structured Query Language
SQL curriculum
SQL curriculum
Preview
These are the chapters that we will approach :
SQL course objectives
Tables used in the course
SQL curriculum
Introduction to SQL
Introduction to SQL
Preview
These are the chapters that we will approach :
What is RDBMS (SGBDR)?
Possibilities Given by
Oracle
SQL
Introduction to SQL
What is a RDBMS?
Relational
Data
B ase
Management
System
Introduction to SQL
What is a RDBMS?
What is a RDBMS?
Data storage on Different media
Electronic
Filing cabinet
spreadsheet Database
Introduction to SQL
What is a RDBMS?
Relational database concept
What is a RDBMS?
Definition of a relational database
What is a RDBMS?
Data Models
Model of
system in
client’s
mind Entity model of
client’s model
Table model of
entity model
Tables on disk
Introduction to SQL
What is a RDBMS?
Entity Relationship Model
Scenario
“...Assign one or more employees to a department...”
“...Some departments do not yet have assigned
employees...”
Introduction to SQL
What is a RDBMS?
Entity relationship modeling conventions
Entity Attribute
Singular, unique name Singular name
Uppercase Lowercase
Soft box Mandatory marked with *
Synonym in parentheses Optional marked with “o”
2 3 4
5
6
1
Introduction to SQL
A relational database:
Can be accessed and modified by executing structured
query language (SQL) statements
Contains a collection of tables with no physical pointers
Uses a set of operators
Introduction to SQL
SELECT department_name
FROM departments;
Introduction to SQL
SQL
S tructured
Q uery
L anguage
Introduction to SQL
SQL
SQL -
A computer language designed for the
retrieval and management of data in
relational database management
systems, database schema creation
and modification, and database object
access control management.
Introduction to SQL
SQL
Provides statements for various tasks, including:
Querying data
Inserting, updating, and deleting rows in a table
Creating, replacing, altering, and dropping objects
Controlling access to the database and its objects
Guaranteeing database consistency and integrity
Introduction to SQL
SQL
Type of statements Statements
SELECT
INSERT
Data manipulation language UPDATE
(DML)
DELETE
MERGE
CREATE
ALTER
DROP
Data definition language (DDL)
RENAME
TRUNCATE
COMMENT
GRANT
Data control language (DCL)
REVOKE
COMMIT
Transaction control (TCL) ROLLBACK
SAVEPOINT