Hey @vel4!
Here's a formula that gets you the basic functionality that you're looking for:
IF(
{Days to Deliver},
IF(
{Days to Deliver} < 0,
"Completed",
IF(
{Days to Deliver} > 7,
"On Time",
IF(
AND(
{Days to Deliver} >= 1,
{Days to Deliver} <= 7
),
"About to Expire"
)
)
),
"Expires Today"
)
Here's an example of how that formula behaves.
It's important to call out a potential downside to this particular formula.
The biggest issue that since the IF function is evaluating the Days to Deliver field for a boolean, the formula will evaluate the value of 0 (zero) as the same as being nothing.
Since both zero and null/undefined evaluate to falsy boolean values, the formula will always return a value of Expires Today for records containing both defined values of zero or blank.
Personally, it would drive me insane, but other people wouldn't even notice it.
It's a matter of personal preference.
Happy to answer any questions about the formula or solutions if you're curious.