Which of the following query displays employees details whose salary is equal to 12000 or 15000 or 18000 or 20000?
select * from employees where salary=(12000,15000,18000,20000)
select * from employees where salary in (12000,15000,18000,20000)
select * from employees where salary=12000 or salary=15000 or salary=18000 or salary=20000
Both Second and third queries are correct .
It is better to write query with 'in' keyword instead of writing multiple conditions in the where clause.
Back To Top