Structure Query Language (SQL)

Structured Query Language (SQL), in the database, is a sublanguage used in querying, updating, and managing relational databases. It was derived from an IBM research project that created Structured English  Query Language (SEQUEL) in the 1970s. SQL is an accepted standard in database products. Although it is not a programming language in the same sense as C or Pascal. SQL can either be used in formulating interactive queries or be embedded in an application as instructions for handling data. The SQL standard also contains components for defining, alerting, controlling, and securing data. SQL is designed for both technical and non-technical users.

Some database system provides a special window or form for creating queries. Because of similar of almost all databases, a common type of query language is developed which are called structured English Query language. The most commonly used command in SQL is the select statements, which is used to retrieve data from tables.
The basic structures of SQL language are as follows.
SELECT field1, field2, … …
FROM table-name
WHERE condition
Query from one table
SELECT name, class, roll, sec
FROM student
Where sec=’a’
This query shows the name, class, roll, sec from student tables which section is A only.
Query from two tables
SELECT name, subject, marks
FROM student, subject
WHERE stid.dtudent=subid.subject

Use of SQL

SQL has the following use for database purposes.
  1. To create database objects such as relations, indexes, etc.
  2. To retrieve or extract data from the database which is called querying the database.
  3. To perform data management tasks such as insertion, modification, and deletion of data from the database.
  4. To work as a prototype.
  5. To provide an easy way to learn commands.

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *