The Alteryx Community is a finalist in three 2026 CMX Awards! Help us win Customer Support Community, Most Engaged Community, and User Group Program of the Year - vote now! (it only takes about 2 minutes) before January 9.
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests Early 2026. Make sure to check your account preferences in my.alteryx.com to make sure you have filled out your security questions. Learn more here
Start Free Trial

Alteryx Designer Cloud Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Cloud.
SOLVED

how can I compare date time?

WuCong
8 - Asteroid

in a table ,I have four fields which display the datetime.

A: 2021-10-01 B:10:01

C:2021-9-18 D :12:00

 

how Can i compare the datetime? when A+B > C+D ,output True else False.

1 REPLY 1
JWang_Tri
Alteryx Alumni (Retired)

If the four columns are already in Date/Time type, then you can compare the addition of the four columns directly and create a new column based on the results.

 

For example, if you're trying to check whether A+B > C+D and output true/false into a separate column, you can use a "New Formula" transform and set the formula to be

IF(A+B>C+D)

Since this creates a new column, remember to provide the new column with a name that best reflects the results of the formula.

 

 

If your field values are in something other than Date/Time type (e.g. String), then you can change the type of the column by clicking on the dropdown menu to the right of the column name > Change type > Date/Time