Posts

Showing posts with the label DAYS

Google Sheets - DAYS function

Image
DAYS function calculates the number of days between two dates. Syntax DAYS(end_date, start_date) Example Notes DAYS(end_date, start_date) is equivalent as DATEDIF(start_date, end_date, "D") In DAYS function, the first argument is end_date, the second argument is start_date, which is different from DATEDIF function.

Excel - DAYS function

Image
The DAYS function returns the difference between two days. =DAYS(C2, B2) For example, the number of days between "7/8/2019" and "1/28/2020" is 204. Internally, Excel convert date value into integers and subtract these two integers. Excel store "7/28/2019" as 43654 and store "1/28/2020" as 43858. And 43858-43654=204, giving the same result as using the DAYS function. Note: The DAYS function needs two arguments, the first one is the end date, the second one is the start date. It is counter-intuitive for many people and different from many other data software, so be very careful.