We use ‘IN’ operator to check whether the records exist in the subquery. IN operator can also be used instead of multiple OR conditions in WHERE clause.
Here is the syntax to use IN operator in SQL:
WHERE column_name IN (value1, value2, ...);
WHERE column_name IN (SELECT STATEMENT);
Here is the statement to find the employees whose location is ‘Bangalore’, ‘Hyderabad’, ‘Chennai’:
SELECT * FROM Employee
WHERE Country IN (Bangalore’, 'Hyderabad', ‘Chennai’);
You can check out this SQL Tutorial blog to learn more about SQL operators with examples.