Solved
IF Nested formula to return a value when value is between two number ranges
I'm trying to build a formula that will look up a currency value from a record, determine whether it is between two ranges of currency, and then enters a percentage (the federal poverty level) in a new column. I'm getting errors in the formula below. Any ideas about what I'm doing wrong?
IF(
{yearly income} < 22763,
"125%",
IF(AND(
{yearly income} > 22763, < 27315),
"150%",
IF(AND({yearly income} > 27315, < 36420),
"200",
IF({yearly income} > 36420,
"Over 200%,
)
)
)
)
Best answer by Ben_Young1
Hey @Rachel_Royal!
Try this:
IF(
{yearly income} < 22763,
"125%",
IF(
AND(
{yearly income} > 22763,
{yearly income} < 27315
),
"150%",
IF(
AND(
{yearly income} > 27315,
{yearly income} < 36420
),
"200%",
IF(
{yearly income} > 36420,
"Over 200%"
)
)
)
)The issue in your original formula was in your AND() functions.
In plain language, you're trying to evaluate statements like: "If yearly income is greater than $22,763 and less than $27,315, then return 150%."
You translated that into your function as:
IF(
AND(
{yearly income} > 22763,
< 27315
),
"150%"
)Your first parameter in the AND() function is valid, but the second one is not.
You should think of each statement for the function to evaluate as isolated and individually scoped from each other, so for the second parameter, the function is only seeing " < 27315" instead of "{yearly income} < 27315" as you intended.
Login to the community
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.



