Introduction
What is SQL?
- SQL stands for Structured Query Language.
- SQL is used to perform C.R.U.D(Create, Retrieve, Update & Delete) operations on relational databases.
- SQL is a structured query language, which is a computer language for storing, manipulating and retrieving data stored in relational databases.
- SQL is the standard for the 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 LanguageDML - Data Manipulation Language
DCL - Data Control Language
DQL - Data Query Language
DDL - Data Definition Language:
DDL - Data Definition Language:
DCL - Data Control Language:
DQL - Data Query Language:
Command | Description |
---|---|
CREATE | Creates a new table, a view of table, or other object in database |
ALTER | Modifies an existing database object, such as a table |
DROP | Delete an entire table , a view of a table or other object in the database |
Command | Description |
---|---|
INSERT | Creates a Record |
UPDATE | Modifies a Record |
DELETE | Delete Record |
Command | Description |
---|---|
Grant | Gives a privilege to user |
Revoke | Takes back privileges granted from user |
Command | Description |
---|---|
Select | Retrieves certain records from one or more tables |