6

When One Is Not Enough: A Query Within a Query

SQL allows for nesting queries, putting a SQL statement within another SELECT statement. Readers familiar with programming concepts might compare it to a nested loop structure, or you can visualize a telescopic tube with nested segments.

Get Discovering SQL: A Hands-On Guide for Beginners now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.