Computer Science, asked by barkha26, 7 months ago

Raj is a database programmer, He has to write the query from EMPLOYEE table to search for
the employee who are not getting any commission, for this he has written the query as:
SELECT * FROM EMPLOYEE WHERE commission=null;
But the query is not producing the correct output, help Raj and correct the query so that he
gets the desired output.​

Answers

Answered by rishabh2004
2

Raj has made a small mistake, he must use LIKE clause here instead of using Equal to (=) to get an appropriate output, and the Query must be like :-

SELECT * FROM EMPLOYEE WHERE COMMISSION LIKE NULL;

And this Query will give him an appropriate output.

Hope it Helps.

Similar questions