The WHERE clause lets you filter results based on specific conditions. It’s used with SELECT to return only the rows that match your criteria.
Here’s the general structure:
SELECT column1, column2 FROM table_name
WHERE condition;For example, if you want to find all students who are 18 years old:
SELECT * FROM students WHERE age = 18;You can use comparison operators like =, >, <, >=, and <= to define your condition.