A Gentle Introduction to

SQL


An interactive SQL tutorial using:

SQL Server, Oracle, MySQL, DB2, Mimer SQL, PostgreSQL and Access.

SELECT statements including joins and functions.

MySQL Performance

Tutorial Section

1) SELECT:
In which we query the CIA World Factbook.
2) SELECT in SELECT:
In which we form queries using other queries.
3) SUM and COUNT:
In which we apply aggregate functions.
4) The JOIN operation:
In which we join two tables; albums and tracks in a music database.
5) More JOIN operations:
In which we join actors to movies in the Movie Database.
6) The OUTER JOIN:
In which we include the parties without people and the people outwith parties in the Scottish Parliament.
SQL User Manuals
[ Mimer | MySQL | Oracle | SQL Server | Access | DB2 | Sybase | Postgres]
Online copies of implementation specific user manuals.
Starting SQL
[ MySQL | Oracle | SQL Server | DB2 ]
How to connect to the server and execute SQL statements.
Programming with SQL
[ SQL in perl on the Web | SQL from Java ]
SQL standard
[ SQL92 BNF ]

Reference Section: how to...

1) CREATE, DROP and ALTER:
[MySQL | Oracle | SQL Server | DB2 | Access | Postgres]
How to create tables, indexes, views and other things. How to get rid of them.
2) INSERT and DELETE
[MySQL | Oracle | SQL Server | DB2 | Access | Postgres]
How to put records into a table, change them and how to take them out again.
3) DATE
[MySQL | Oracle | SQL Server | DB2 | Access | Postgres]
How to work with dates; adding, subtracting and formatting.
4) FUNCTIONS
[MySQL | Oracle | SQL Server | DB2 | Access | Postgrei]
How to use string functions, logical functions and mathematical functions.
5) USERS
[MySQL | Oracle | SQL Server | DB2 | Access | Postgres]
How to create users, give them access, get at other peoples tables. How to find processes and kill them.
6) META DATA
[MySQL | Oracle | SQL Server | DB2 | Access | Postgres]
How to find out what tables and columns exist. How to count and limit the rows return.

Assessments

Answers

Other information

Diversions

By Andrew Cumming of the School of Computing of Napier University, Edinburgh, UK. 1999-2003

Original at http://sqlpass-latam.org [ English | French | German | Italian | Portuguese | Spanish ]

Automatically generated translations are experimental. I have plans to incorporate human translations, any suggestions or offers of help would be greatly appreciated.