Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
beatkeeper25
Starting Member
27 Posts |
Posted - 2013-08-06 : 15:41:01
|
Can someone translate what this line is doing? AND ISNULL(a.completiondate,0)<ISNULL(b.completiondate,0)what is the purpose of the ,0 ? |
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2013-08-07 : 00:55:37
|
basically the purpose of this is to handle NULL values as well. If you just use it like belowa.completiondate < b.completiondate it will cause the cases where one of the column values is NULL to be ignored as operators like <,> etc will ignore NULL under default conditions (ANSI NULL settings) in SQL Server------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/https://www.facebook.com/VmBlogs |
 |
|
|
|
|