02 - What is SQL

Now consider we created a database for an application, but how would you retrieve data from the tables. SQL (Structured Query Language) is a standard language designed for managing data in relational tables.  This language is used by all the relational database systems. SQL allows users to create databases, add data, modify, maintain data and fetch selected data. It is governed by standards maintained by ISO (International Standards Organization).

Benefits of SQL:

  1. SQL Is non procedural, that means you do not need to write lengthy programs to get data, there are commands, expressions and operators to use to get data from tables.
  2. SQL Is portable, databases using sql can be moved from one device to another without any problems.
  3. Easy to learn as SQL is in form of ENGLISH statements.

Consider the example of the data entered through the website, you have to retrieve the data like your profile details using the username, then the sample SQL that can be used would be

SELECT * FROM wb_Profile_table

Where username = entered_username;

Thus SQL commands can be used to create databases, edit data in the tables, delete data and maintain data in the tables.

SQL commands are classified into 3 groups:

1. DDL(Data definition Language)

DDL includes commands related to creation and deletion of databases and tables.

  • DROP​​


2. DML(Data Manipulation Language)

DML includes commands related to creation, editing and deletion of records in tables.



3. DCL(Data control Language)

DCL includes commands through which the user control can be maintained.

  • ​GRANT



Like us on Facebook