blog post

SQL was designed to be entered on a console and results would display back to a screen.
Today, SQL is mostly used by programmers who use SQL inside their language to build applications that access data in a database.

The syntax of a language describes the language elements.
SQL statements are somewhat like simple English sentences.
Keywords include SELECT, UPDATE, WHERE, ORDER BY, etc.
ANSI Standard SQL is the lingua franca for relational databases.

SQL Syntax

Four fundamental operations that apply to any database are:
Read the data -- SELECT
Insert new data -- INSERT
Update existing data -- UPDATE
Remove data -- DELETE

Collectively these are referred to as CRUD (Create, Read, Update, Delete).

The SQL SELECT general form

SELECT column-names
FROM table-name
WHERE condition
ORDER BY sort-order


SELECT FirstName, LastName, City, Country 
FROM Customer
WHERE City = 'Paris'

The SQL INSERT general form

INSERT table-name (column-names)
VALUES (column-values)


INSERT Supplier (Name, ContactName, City, Country)
VALUES ('Oxford Trading', 'Ian Smith', 'Oxford', 'UK')

The SQL UPDATE general form

UPDATE table-name
SET column-name = column-value
WHERE condition


UPDATE OrderItem
SET Quantity = 2
WHERE Id = 388

The SQL DELETE general form

DELETE table-name
WHERE condition


DELETE Customer
WHERE Email = ''

  • Share This Story

Pleas give your valuable comments to improve the contents.

about author

Atul kumar shukla

I'm Atul Kumar Shukla, working as a web developer.
Welcome to my Blog. This is my personal blog where i post my own questions and answers , articles about ASP.Net., SQL Server, HTML, CSS, Jquery and many more..

Visit Profile

Leave a comment


Get More Stuff
Subscribing to the TheOneblogs newsletter and get intersting stuff and updates to your email inbox.
Your Email


Style Switcher

Change Color

×! We use cookies to improve your user experience. More information