Reference Guide > TDV Support for SQL Functions > TDV-Supported Date Functions > DAYS
 
DAYS
The DAYS_BETWEEN function returns the number of days since January 1, 0001, including that beginning date.
Syntax
DAYS (date_expression)
Remarks
TDV natively implements the version of the DAYS function.
The Excel DAYS function is far different from the TDV/ DAYS function.
Examples
SELECT DAYS ('0001-01-02')
 
This example returns 2.
SELECT DAYS ('2001-01-02')
 
This example returns 730487.