-- Data Definition Language (DDL)

-- Subset of SQL used to define and manage the structure of a database (Schmeas, tables, indexes)

-- Examples 
-- CREATE - Create a new table or database 
-- ALTER - Modify the structure of an existing table 
-- DROP - Delete a table or database 

-- Purpose: Deals with schema-level changes, not the actual data inside the tables 


-- Data Manipulation Langauge (DML)
-- Subset of SQL used to maniuplate the data stored in the database 

-- Examples 
-- SELECT - Retrieve Data 
-- INSERT - Add new Data 
-- UPDATE - modify existing data 
-- DELETE - Remove Data 

-- Purpose it deals with row-level operations, changing or querying the actual data. 

-- KEY DIFFERENCE 
-- DDL - Defines Structure (Tables, Columns, constraints)
-- DML - Manipulates data (Rows inside the table)


-- FOREIGN KEY - in the child table references a primary key or unique key in the parent table to maintain referential integrity 
-- Ensures that every foreign key value corresponds to an existing record in the parent table 


-- Data Control Language (DCL) - it is a sublanguage of SQL used to manage access and permissions in a database. 
-- Commands control who can do what on database objects. 

-- GRANT -- Gives a user specific prvileges on a Database object 
-- REVOKE -- Removes previously granted privileges

-- Purpose - Ensures security and controlled access to data, works alongside authentication and roles. 

-- Referential Integrity - is a concept in relational databases that ensures the relationships between tables remain consistent 

-- Means that a foregin key in one table must either: 
-- match a primary key value in another table or be NULL (if allowed)
-- Prevents orphaned records and maintains valid links between related data. 

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: