Advertisement

Querying Multiple Tables

  • Cristian Darie
  • Karli Watson
  • Chris Hart
  • Kevin Hoffman
  • Julian Skinner

Abstract

Querying data from multiple tables using subqueries is a great capability, but it doesn’t always give you everything you need, and the syntax can become a bit messy and confusing. Also, as discussed in the previous chapter, when a sub-query executes for each match of an outer query, performance can be affected. For this reason, SQL allows you to query multiple tables simultaneously with a simpler syntax. This capability doesn’t completely replace some of the techniques you saw in the previous chapter involving subqueries across multiple tables, but it’s extremely powerful when you simply want a result set that contains information from more than one table. Because relational databases are designed to hold data in more than one table, where records in one table are usually associated with records in other tables, this functionality is essential.

Keywords

Previous Chapter Source Table Class Table Multiple Table Simple Syntax 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Copyright information

© Cristian Darie, Karli Watson with Chris Hart, Kevin Hoffman, Julian Skinner 2003

Authors and Affiliations

  • Cristian Darie
  • Karli Watson
  • Chris Hart
  • Kevin Hoffman
  • Julian Skinner

There are no affiliations available

Personalised recommendations