DBA > Job Interview Questions > Microsoft SQL Server FAQs

What does this WHERE clause evaluate to?

More DBA job interview questions and answers at http://dba.fyicenter.com/Interview-Questions/

(Continued from previous question...)

What does this WHERE clause evaluate to?

What does this WHERE clause evaluate to? (there are rows with NULL values)
select top 10 *
from MyTable
where Myid = NULL


Answer: Unknown

Explanation: The expression "MyID = NULL" evaluates to Unkown rather than any true or false condition.

(Continued on next question...)

Other Job Interview Questions