Skip to main content
SQL • LESSON 06

AND / OR Conditions

How can we filter records using multiple criteria simultaneously?

Beginner2 Minutes130 XP
🤔 THE QUESTION

How can we filter records using multiple criteria simultaneously?

💡 WHAT IS IT?

AND requires all conditions to evaluate to true, while OR requires at least one condition to be true.

🎯 WHAT IS IT USED FOR?

Multi-dimensional filtering such as department, region, status, and salary simultaneously.

💻 EXAMPLE
SELECT *
FROM employees
WHERE department = 'IT'
AND salary > 50000;

🎯 Mission Objectives

Practice typing production-grade SQL code for AND / OR Conditions.

  • AND
  • Compound conditions
  • WHERE
  • Logical operators