What is the result, when NULL is compared with NULL?
Answer Posted / affan shemle
It is absolutely perfect to compare NULL with NULL. It
yields the result NULL. For those who are saying the result
is FALSE they are taking the answer from IF THEN ELSE. In
all the above answers supported by IF Statement there is a
catch. The result of IF is a Boolean. A Boolean can hold
TRUE, FALSE or NULL. So when you compare NULL vs NULL as a
condition of IF THEN, it returns NULL so the controller goes
to ELSE skipping the IF. Makes sense???
/
AFFAN SHEMLE
| Is This Answer Correct ? | 13 Yes | 1 No |
Post New Answer View All Answers
What is numeric function sql?
what are the performance and scalability characteristics of mysql? : Sql dba
What is right join in sql?
What is a schema? How is it useful in sql servers?
Is keyword pl sql?
What does closing a cursor do?
How would you pass hints to the sql processor?
How many disk partitions should I have?
What is the difference between the implicit and explicit cursors?
What is Collation Sensitivity ? What are the various type ?
Can we use loop in sql?
What is the difference between the repeatable read and serializable isolation levels? : Transact sql
How do I view a procedure in sql?
What is a database trigger?
how to implement one-to-one, one-to-many and many-to-many relationships while designing tables? : Sql dba