Skip to main content
SQL โ€ข LESSON 46

IN

How can we match a column against several possible values?

Beginnerโฑ 3 Minutesโญ 590 XP
๐Ÿค” THE QUESTION

How can we match a column against several possible values?

๐Ÿ’ก WHAT IS IT?

The IN operator checks whether a column value matches any value within a discrete list of literals or subquery results.

๐ŸŽฏ WHAT IS IT USED FOR?

Targeting specific departments, status flags, country lists without repeating multiple OR statements.

๐Ÿ’ป EXAMPLE
SELECT name, department
FROM employees
WHERE department IN ('Engineering', 'Analytics', 'Finance');

๐ŸŽฏ Mission Objectives

Practice typing production-grade SQL code for IN.

  • โœ“ IN operator
  • โœ“ Set membership
  • โœ“ List filtering
  • โœ“ Clean syntax