Hi all,
I need help coming up with a formula to:
1. Pull today's date (date only)
2. Compare it to the target hire date.
3. If today's date is within 30 days of the target hire date (i.e. Today's date - target hire date < 30)
4. Then add 30 days to the estimated hire date (new column called new target hire date)
My current formula is (wrong):
IF DateTimeNow()-[Target Hire Date]<30
THEN DateTimeAdd([Target Hire Date],30,"days")
ELSE [Target Hire Date]
ENDIF
Solved! Go to Solution.
Hey @dareinnyc
if DateTimeDiff([DateTimeNow(), [Target Hire Date], 'days') < 30
then DateTimeAdd([Target Hire Date],30,"days")
else [Target Hire Date]
endif
Let me know if this works.
P
Classification: Internal
Hi, this doesn't seem to work as it is still adding 30 days to all target hire dates after datetimenow. The logic should only add 30 days to the target hire date should the original target hire date be less than 30 days from datetimenow. Thanks
Its ok, i switched the fields around and it works now.
IF DateTimeDiff([Target Hire Date],DateTimeNow(), 'days')<30
THEN DateTimeAdd([Target Hire Date],60,"days") ELSE [Target Hire Date]
ENDIF
User | Count |
---|---|
17 | |
15 | |
15 | |
8 | |
5 |