Quantcast
Channel: SQLServerCentral » SQL Server 2014 » Development - SQL Server 2014 » Latest topics
Viewing all articles
Browse latest Browse all 3145

query compare date

$
0
0
I have a table, in each row, I have an CaseID, MTDThresholdDate, and YTDThresholdDateBoth of the date could be null, I would like to return what is the earlier date or smaller date.If either of them is null, return the date that is not null.If both null then null, if there is one null, then return non-null date.Can anyone help, thanks

Viewing all articles
Browse latest Browse all 3145

Trending Articles