W3Schools

home HOME

SQL Basic
SQL HOME
SQL Intro
SQL Select
SQL Where
SQL Insert
SQL Update
SQL Delete

SQL Demo
SQL Try It

SQL Advanced
SQL Order By
SQL and & or
SQL In
SQL Between
SQL Aliases
SQL Join
SQL Union
SQL Create
SQL Drop
SQL Alter
SQL Functions
SQL Group By
SQL Select Into
SQL Create View
SQL Server

SQL Quick Ref
SQL Summary

SQL Quiz
SQL Quiz

Selected Reading
Web Statistics
Web Glossary
Web Hosting
Web Quality

W3Schools Forum

Helping W3Schools

SQL Tutorial

previous next

SQL Tutorial

SQL

SQL is a standard computer language for accessing and manipulating databases.

In this tutorial you will learn how to use SQL to access and manipulate data in Oracle, Sybase, SQL Server, DB2, Access, and other database systems.

Start learning SQL now!


Table Of Content

SQL Intro
An introduction to SQL.

SQL SELECT
How the SELECT statement is used to select data from a database.

SQL WHERE
How the WHERE clause is used to conditionally select data.

SQL INSERT INTO
How the INSERT INTO statement inserts new records (rows) into a database table.

SQL UPDATE
How to modify data in a database using the UPDATE statement.

SQL DELETE
How to delete records (rows) in a database, using the DELETE statement.

SQL Demo

SQL Try-It-Yourself
Try some SQL statements of your own.

SQL Advanced

SQL ORDER BY
The ORDER BY keyword is used to sort the result.

SQL AND & OR
AND and OR join two or more conditions in a WHERE clause.

SQL IN
The IN operator may be used if you know the exact value(s) to search for.

SQL BETWEEN
The BETWEEN operator selects a range of data between two values.

SQL ALIAS
Aliases can be used for column names and table names.

SQL JOIN
How to use the JOIN operator to select data from two or more tables.

SQL UNION
The UNION operator is used to select related information from two tables.

SQL CREATE
How to create a new database and / or a new database table.

SQL DROP
How to drop (delete) a database and /or a database table.

SQL ALTER
How to user ALTER to add or delete table columns.

SQL Functions
SQL has a lot of built-in functions for counting and calculations.

SQL GROUP BY
How to use GROUP BY to group aggregated data.

SQL SELECT INTO
How to use SELECT INTO to save selected data in tables (create backup copies).

SQL CREATE VIEW
How to create a virtual table using CREATE VIEW.

SQL Server
About Database Management Systems (DBMS).

SQL Quick Reference
An SQL Quick Reference. Print it, fold it, and put it in your pocket.

SQL Summary
A summary of this tutorial.

SQL Quiz Test

Start SQL quiz!
Test your SQL skills at W3Schools!


previous next




Jump to: Top of Page or HOME or Printer Friendly Printer friendly page

W3Schools provides material for training only. We do not warrant the correctness of its contents. The risk from using it lies entirely with the user. While using this site, you agree to have read and accepted our terms of use and privacy policy.

Copyright 1999-2008 by Refsnes Data. All Rights Reserved.

Validate Validate W3C-WAI level A conformance icon W3Schools was converted to XHTML in December 1999