Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I have a dashboard in which the creator has used the following script statement
Load
T_End-(floor(today())) as NoOfDaystoEndDate,
*;
I thought 'floor' was used for rounding down, and Today() for returning today's date. The statement doesn't make sense.
Can someone please explain what is happening ?
Thanks
MV
floor() rounds a value down to the nearest integer.
For date-time fields, floow will remove the time portion so just the date part is used.
The script is calculating the difference between today's date
and T_End
Assuming that T_End is a date.
perhaps the command should be
floor( T_End - today() ) as NoOfDaystoEndDate
floor() rounds a value down to the nearest integer.
For date-time fields, floow will remove the time portion so just the date part is used.
The script is calculating the difference between today's date
and T_End
Assuming that T_End is a date.
perhaps the command should be
floor( T_End - today() ) as NoOfDaystoEndDate
Floor(Today()) returns the same of (Num(Today()) so convert the date in its numerical representation, in this case nothing else because there is not time part ...
Thanks both. That makes sense now. I never thought of the time element.