The DATEDIFF() function returns the time between two dates.
Where date1 and date2 are valid date or date/time expressions.
Note: Only the date parts of the values are used in the calculation.
The following SELECT statement:
will result in this:
DiffDate |
---|
1 |
The following SELECT statement:
will result in this:
DiffDate |
---|
-1 |