Mar 03, 2021 01:24 AM
Hi, I’m super new to using formulas. I’d like to do an IF formula for my “Published date” column with the “assigned week” column.
So if the dates are less than 2 weeks time it will get “first two weeks” if its more than two weeks it will get the “last two weeks”.
My formula:
IF({Published date}) < 14, “first two weeks”) ,IF({Published date}) > 14,“last two weeks”)
Please advised… Thanks in advance!
Mar 03, 2021 05:05 AM
You’re probably looking for DATETIME_DIFF. Give this a try:
IF(DATETIME_DIFF({Published date}, TODAY(), "days") < 14, "first two weeks", "last two weeks")
That will check the number of days between {Published date} and Today, but it’s possible to replace TODAY()
with another Date field.
Hope that helps.
Mar 03, 2021 07:56 AM
Hey thanks, it works! new formula to play around with. I’m going to keep it to a month to month basis because anything that’s more than 14 days shows as “last two weeks”. :slightly_smiling_face: