Flag overdue invoices with IF and NOT
BeginnerWhen tracking invoices, you often need to flag those that are overdue but not yet paid. Combining IF with NOT lets you test "if something is NOT the case."
The NOT function reverses a TRUE or FALSE result:
=NOT(logical_test)
If the logical test is TRUE, NOT returns FALSE. If it is FALSE, NOT returns TRUE. This makes it useful when you want to check that a condition does not apply.
What you need to do
This sheet has six invoices with due dates and payment statuses. In this exercise, every invoice shown is already past its due date, so the only thing you need to check is whether the status is not "Paid".
Some overdue invoices use different status labels, so this is a good case for checking what the status is not, rather than looking for just one unpaid label.
Your goal is to fill the Flag column (column D) with:
"Overdue"when the status is not "Paid"""(empty string) for any other case
Follow these steps:
- Click cell D4 (the first Flag cell, for INV-1001).
- Start with an IF formula:
=IF(logical_test, "Overdue", "") - For the logical test, use NOT to reverse the status check.
NOT(C4="Paid")returns TRUE whenever the invoice status is anything other than "Paid". - Press Enter.
- Copy the formula from D4 down to D9.
Quick check: INV-1002 and INV-1006 are paid, so they should show empty. The other four invoices should show "Overdue", even though their non-paid statuses are written in different ways.
Need some help?
Hint 1
Start with IF: =IF(logical_test, "Overdue", "").
Hint 2
Use NOT to reverse the status check: NOT(C4="Paid") is TRUE when the invoice is not paid.
Hint 3
Because some overdue invoices use different non-paid status labels, checking NOT("Paid") is more reliable than checking for one single word like "Unpaid".
Hint 4
Put that NOT check inside IF, so your formula in D4 returns "Overdue" for any non-paid status and an empty string for paid ones.
Flag overdue invoices with IF and NOT
BeginnerWhen tracking invoices, you often need to flag those that are overdue but not yet paid. Combining IF with NOT lets you test "if something is NOT the case."
The NOT function reverses a TRUE or FALSE result:
=NOT(logical_test)
If the logical test is TRUE, NOT returns FALSE. If it is FALSE, NOT returns TRUE. This makes it useful when you want to check that a condition does not apply.
What you need to do
This sheet has six invoices with due dates and payment statuses. In this exercise, every invoice shown is already past its due date, so the only thing you need to check is whether the status is not "Paid".
Some overdue invoices use different status labels, so this is a good case for checking what the status is not, rather than looking for just one unpaid label.
Your goal is to fill the Flag column (column D) with:
"Overdue"when the status is not "Paid"""(empty string) for any other case
Follow these steps:
- Click cell D4 (the first Flag cell, for INV-1001).
- Start with an IF formula:
=IF(logical_test, "Overdue", "") - For the logical test, use NOT to reverse the status check.
NOT(C4="Paid")returns TRUE whenever the invoice status is anything other than "Paid". - Press Enter.
- Copy the formula from D4 down to D9.
Quick check: INV-1002 and INV-1006 are paid, so they should show empty. The other four invoices should show "Overdue", even though their non-paid statuses are written in different ways.
Need some help?
Hint 1
Start with IF: =IF(logical_test, "Overdue", "").
Hint 2
Use NOT to reverse the status check: NOT(C4="Paid") is TRUE when the invoice is not paid.
Hint 3
Because some overdue invoices use different non-paid status labels, checking NOT("Paid") is more reliable than checking for one single word like "Unpaid".
Hint 4
Put that NOT check inside IF, so your formula in D4 returns "Overdue" for any non-paid status and an empty string for paid ones.