0% found this document useful (0 votes)
41 views

1.1 PPT - Basic Concept of Relational Database

The document provides an introduction to relational database management systems (RDBMS) concepts. It defines key terms like RDBMS, tables, fields, rows, columns and null values. It also covers database keys, the difference between DBMS and RDBMS, and SQL commands for data definition, data manipulation, and data queries. Examples of SQL queries are provided to demonstrate concepts like selecting records, joins, and aggregate functions. A YouTube link is included to further explain the introduction to RDBMS.

Uploaded by

amaan
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
41 views

1.1 PPT - Basic Concept of Relational Database

The document provides an introduction to relational database management systems (RDBMS) concepts. It defines key terms like RDBMS, tables, fields, rows, columns and null values. It also covers database keys, the difference between DBMS and RDBMS, and SQL commands for data definition, data manipulation, and data queries. Examples of SQL queries are provided to demonstrate concepts like selecting records, joins, and aggregate functions. A YouTube link is included to further explain the introduction to RDBMS.

Uploaded by

amaan
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 62

Objective:

• There are many distinct objectives that you must


achieve in order to design a good, sound, structured
database.

• You can avoid many of the problems you may


encounter by keeping the following objectives in
mind and constantly focus on these whilst designing
your database.
Content:
• What is RDBMS?
• Difference between DBMS and RDBMS
• What is Table?
• What is Field?
• What is Row or Record?
• What is Column?
• What is Null Value?
• Database Key
• Types of Key
YouTube Link:

• This YouTube link regarding Introduction to


RDBMS with example

https://www.youtube.com/watch?v=3EJlovevfcA
1.1 Assignment
University Question :
1. Difference between DBMS and RDBMS
2. Explain database keys with example

Logical Question:
1. Retrieve record of students those belongs to
shahapur using SQL Query
What is SQL?

 Structured Query Language


 SQL is Structured Query Language, which is a computer
language for storing, manipulating and retrieving data stored
in relational database.

 SQL is the standard language for Relation Database System. All


relational database management systems like “MySQL, MS
Access, Oracle, Sybase, Informix, postgres and SQL Server”
use SQL as standard database language.
SQL Commands

 DDL - Data Definition Language

 DML - Data Manipulation Language

 DCL - Data Control Language

 DQL - Data Query Language


Language
SQL Commands
SQL Commands
SQL RDBMS Concepts

 TABLE
 RECORD
 COLUMN
 CELL

 NULL?
SQL RDBMS Concepts
 SQL Constraints: (applied on columns)
 NOT NULL Constraint
 UNIQUE Constraint
 PRIMARY Key
 FOREIGN Key
 CHECK Constraint
 Data Integrity:
 Entity Integrity: There are no duplicate rows in a table
 Domain Integrity: Enforces valid entries for a given
column by
restricting the type
 Referential Integrity: Rows cannot be deleted which are used by

other records
 User-Defined Integrity: Enforces some specific business rules
SQL RDBMS Concepts
 Data Types:
 Character datatypes:
 CHAR
 NCHAR
 NVARCHAR2
 VARCHAR2
 Numeric datatypes:
 NUMBER
 BINARY_FLOAT
 BINARY_DOUBLE
 Date time datatype:
 DATE
DCL: CREATE USER

 1) Define User with Username/Password


 2) Grants Sufficient Privileges.

 Using SQL Developer (UI, Command)


 Using SQL *PLUS (Command)
SQL : DDL
 Create Table:
 COLUMNS
 CONSTRAINTS
SQL: DDL

 DROP
TABLE:

 ALTER
TABLE

 OTHER DDL
COMMANDS!!!!
SQL: DML: INSERT
 INSERT INTO:
 NUMBER, CHAR/VARCHAR2,
DATE?
SQL: DML: INSERT
 INSERT INTO:
 SPECIFIC
COLUMNS
SQL: DML: INSERT
 INSERT INTO:
 FOREIGN
KEY

 ALL DML COMMANDS NEED


COMMIT
SQL: DML: UPDATE

UPDATE

 WHERE
CLAUSE
SQL: DML:
DELETE
 DELETE (DELETE VS
DROP????)
YouTube Link : Introduction to SQL

https://www.youtube.com/watch?v
=323H_mOOWQ4
SQL: DQL: SELECT

SELECT
 *

 SPECIFIC
COLUMNS
SQL: DQL:
SELECT
 DISTINCT
CLUASE
SQL: DQL:
SELECT
 WHERE
CLUASE
SQL: DQL: SELECT
IN
CLUASE
 NOT IN

 NULL IN
WHERE?
 IS NULL
 IS NOT NULL
SQL: DQL:
SELECT
 ORDER
BY
SQL: DQL: SELECT
 GROUP BY

 AGGREGATE
FUCTION
 MAX,MIN
 AVG
 COUNT
 SUM
 …
 HAVING CLAUSE
SQL: DQL: SELECT
 SELECT FROM MULTIPLE
TABLES
 CARTESIAN MULTIPICATION

 JOIN

You might also like