Date Calculation

Date Calculation

Comments

  • [color=rgb(77, 77, 77)][font=Helvetica Neue, Arial, Helvetica, sans-serif]Build ability to evaluate the total number of days between “Date A” and Today’s Date. If greater than 15 days then return true, otherwise false.[/font][/color]

  • Unknown
    edited November 2023

    To be able to get total number of days between two Dates we can use Day of year property from Date Time type. For example:
    we can build a Flow that has Date Time variable input. We would like to evaluate if the difference between today Date and Flow input Date is more than 15 days. First we add Get Current Date step from Data > Dates category. Then, we add Subtract step from Data > Numbers category. Finally, we add Greater Than step from the Data > Numbers category. Our Flow should look as following...

    Then, in Subtract step we map our data to subtract Day of year property of the Flow input Date from the Day of year value of the Current Date.

    Finally, in the Greater Than step we check if the result of Subtract step is greater than 15. If it is, our Rule step will return True, otherwise it will return False.
    [i]edited by Vitalii Titushyn on 2/29/2016[/i]
    [i]edited by Vitalii Titushyn on 2/29/2016[/i]

Sign In or Register to comment.