Dedication
Acknowledgments
Introduction
Platforms used in the Book
Chapter 1. The Relational Database
and Structured Query Language
The Relational Database Structure
Structured Query Language
Chapter 2. Creating Tables and
Working with Data
Table Creation
Inserting Data Into a Table
Transferring Data from One Table to an Existing Table
Transferring Data from One Table to a New Table
Updating Data in a Table
Deleting Data in a Table
Chapter 3. Selecting and Retrieving
Data
The SELECT Statement
Creating a SELECT Statement to Retrieve Multiple Columns
Creating a SELECT Statement to Retrieve Every Column
Using DISTINCT to display Unique Values in a Column
Using the AS Keyword to Create an Alternate Name for a Column
Merging Columns
Uniting Queries to Compare Records in Two Separate Tables
Chapter 4. Filter Retrieved Data
The WHERE Clause
Using a Comparison Operator to Match a Condition
Using a Character Operator to Match a Condition
Using a Logical Operator to Match a Condition
Using a Logical Operator to Match a Condition Opposite of the One
Defined
Using the IN Operator to Match a Condition
Using the BETWEEN Operator to Match a Condition
Chapter 5. Creating Calculated
Fields
Calculated Fields
Concatenation
Arithmetic Operators
Functions
Chapter 6. Using Additional Clauses
in Structured Query
Language
Clauses
Using the ORDER BY Clause
Using the GROUP BY Clause
Using the GROUP BY and WHERE Clause
Using the HAVING Clause
Chapter 7. Creating Table Joins
Table Joins
Qualification
Self Join
Natural Join
Outer Join
Chapter 8. Creating Subqueries
Subqueries
Using the IN keyword to link Queries
Using the EXISTS keyword to link Queries
Using the ANY keyword to link Queries
Using the ALL keyword to link Queries
Creating Subqueries to Query Three Tables
Chapter 9. Creating Views
Views
Creating a View on One Table
Creating a View on Multiple Tables
Filtering Table Data Using a View
Updating and Inserting Data into Tables Using Views
Deleting a View
Chapter 10. Advanced Table Creation
and Table Management
Table Creation
Constraints
Indexes
Table Management
Adding a Column
Deleting a Column
Deleting a Table
Chapter 11. Advanced Topics:
Transaction Processing, Stored Procedures, Triggers and Cursors
Transaction Processing
Stored Procedures
Triggers
Cursors
Appendix A
Answers to Quizzes and Assignments
Appendix B
SQL Script for the Tables Used in
the Book:
http://www.angelfire.com/ca2/n4systems/BookScript.html
Appendix C
SQL Command Syntax
Appendix D
Instructions on Where to Type SQL
Script in Microsoft Access and Microsoft SQL Server
Index
View the SQL script for creating
tables used in the book.
http://www.jaffainc.com/SQLBookScript.html
View the SQL course entitled
“Introduction to SQL”.
http://www.jaffainc.com