5

Filtering Rows

In this chapter:

  • How do you filter rows out of a query?

  • What are conditional comparisons?

  • What are logical operators?

This chapter extends the syntax of the SELECT statement by examining WHERE clause filtering, conditional comparisons, and logical operators. Filtering is a process of retrieving a subset of the rows retrieved by the SELECT statement.

5.1 WHERE Clause Syntax

We saw two of the primary parts (or clauses) of an SQL query in the previous chapter, namely the SELECT clause and the FROM clause. This chapter adds the WHERE clause. Here is a quick description of each clause:

  • SELECT. List all the columns you want to see in your report here. Separate them with commas. Use an asterisk (*) instead of a list of columns to ...

Get Oracle SQL now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.