© The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature 2023
M. SimonGetting Started with SQL and Databaseshttps://doi.org/10.1007/978-1-4842-9493-2_3

3. Filtering Data

Mark Simon1  
(1)
Ivanhoe VIC, VIC, Australia
 

One of the main roles of a DBMS is to store data. The other main role is to retrieve it. To retrieve data, you use the SELECT statement. However, you often don’t want all the data, so you will want to filter the results.

In this chapter, we’ll look at how you filter your requests with a WHERE clause. As we do, we’ll cover important topics such as
  • How the WHERE clause works

  • Working with missing values

  • Working with different data types: numbers, strings, and dates

  • Combining filters

  • Working with “wildcards”

If you have ...

Get Getting Started with SQL and Databases: Managing and Manipulating Data with 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.