Use the menu on the left for syntax, descriptions and examples of SQL commands.
Introduction to SQL
Structured Query Language, or SQL (pronounced sequel), is a computer language aimed to store, manipulate, and query data stored in relational databases. SQL first appeared in 1974, when a group at IBM developed a prototype of a relational database. The first commercial relational database was produced by the company which would later become Oracle.
SQL Variations
SQL syntax differs with each database product. The most common SQL databases in use are mySQL, Microsoft SQL Server, Oracle and postgreSQL. The bulk of the SQL syntax used is the same across all databases. Any variations between the SQL used by the various vendors will be noted as we come across them. Most of the differences are small and generally diverge on how data types are handled, particularly NULL values.
Learning SQL
Count SQL is a SQL tutorial and syntax site. The layout can be broadly broken down into two sections: articles and syntax. The articles give a rough overview of the main variants of SQL servers along with a walk through where we develop a SQL database step by step. The syntax section describes the most common SQL statements along with their syntax, description and examples.
SQL Articles
- MySQL - A primer on the mySQL server.
- MS SQL Server - A primer on Microsoft SQL Server.
- PostgreSQL - A primer on postgreSQL.
- SQL Tutorial - A step by step SQL tutorial.
SQL Queries
The SQL statement section is divided into Table Manipulation, SQL Queries and Advanced SQL. The SQL syntax, description and examples are given for each SQL statement. All can be accessed via the menu on the left.
Recomended Approach
Our recommended approach to learning SQL is to follow the walkthrough tutorial. If you need more information on any given SQL statement, query or clause you can look up the syntax for that command on the menu on the left.
For each command, the SQL syntax will first be presented and described along with examples. Differences between the various SQL server implementations will be noted where appropriate. For more information on each SQL server vendor, you can view their individual descriptions from the menu on the left.