IS NOT NULL

Published Jun 25, 2021Updated Aug 18, 2022
Contribute to Docs

The IS NOT NULL operator checks if a value is not equal to NULL.

Syntax

SELECT column_name(s)
FROM table_name
WHERE condition IS NOT NULL;

Example

The given query will select all customers who have a birthday stored in the database.

SELECT *
FROM customers
WHERE birthday IS NOT NULL;

All contributors

Looking to contribute?

Learn SQL on Codecademy