PostgreSQL
PostgreSQL IN
Check whether a value matches one of several values.
Match a list
SELECT * FROM products
WHERE year IN (2024, 2025, 2026);IN is a concise alternative to several OR comparisons. It can also compare against a subquery.
SELECT * FROM products
WHERE year IN (SELECT year FROM featured_products);