Ghost Sheet

IFERROR, and when it hides a problem

How do I show a message instead of an error?

This is the task for this topic. It is part of the plan; the level check before it is free.
D2Type a formula for D2, starting with =

Click the sheet or the button: the task opens in your workspace, ready to type

ABCDE
1SKUTotal costQtyUnit cost
2TP-11072550
3BX-2041,947.595
4GL-31822040
5MK-4222,625125
6EN-53615015
7ST-64028595
8LB-754312.525
9FD-868357.555
10RB-9721,820140
11CL-18617510
12PN-29035050
13
14
15
16
17
18
19
20
21
dashed: the answer to reachblack: matchesblue: right after new datared: wrong

Why it works

What it does
IFERROR(formula, value) returns the value whenever the formula gives any error. It is right when you know which error you expect, such as division by a zero quantity. IFNA catches only #N/A, which is safer around lookups.
The shape of the formula
=IFERROR(calculation, what to show instead)
How to remember it
IFERROR is a blanket: use it only when you know what is under it.
The usual mistake
Wrapping a long formula in IFERROR “just in case”. A typo or a missing sheet now shows a calm message instead of an error.

Keep practicing

Updated