Conditional Aggregates


While working with databases, it's common to have empty or unknown "cells" in data tables. For example, in our first flights table, we keep track of when flights arrive in a column called arr_time:

alt text

In this table, the third flight was canceled and therefore did not have an arrive time. We'll leave this cell empty, which is denoted as NULL.

What do we do when we need to test whether a value is or is not null? We use the special keywords IS NULL or IS NOT NULL in the WHERE clause (= NULL does not work).

Community Forums
Get help and ask questions in the Codecademy Forums
Report a Bug
If you see a bug or any other issue with this page, please report it here.