DEV Community

Juliet Kathuke
Juliet Kathuke

Posted on

Introduction to SQL

SQL stands for Structured Query Language. It enables users to communicate with databases. It is used to retrieve data,Update records and manage database structures.
To create a Database or tables CREATE function is used,
for Example CREATE DATABASE storeDB; - a database created called storeDB.
Now let's create a table called sales:
CREATE TABLE sales (saleID INT PRIMARY KEY,productName VARCHAR(30),customerID INT );
To retrieve data, SELECT Function is used. Data is selected from a table, for example SELECT * from Sales;
In the example above, we are selecting all rows from Sales table.

Top comments (0)