Lab › Fixes & Errors › Fix #N/A: Code Not Found
Fix #N/A: Code Not Found: Excel Lab
Lab 22 · IntermediateVLOOKUP (exact match)IFERROR
The task: Look up each product's price. Some codes are not in the price list; show 'Not found' and an amount of 0.
1 Watch how it is done
Step 1: Look up the price, catch #N/A
=IFERROR(VLOOKUP(A4,$F$4:$G$8,2,FALSE),"Not found")- Click C4.
- Type =IFERROR(VLOOKUP(A4,$F$4:$G$8,2,FALSE),"Not found") and press Enter.
- FALSE = exact match. A missing code gives #N/A, so IFERROR shows Not found.
- Drag the fill handle down.
Step 2: Amount, 0 when price is missing
=IFERROR(B4*C4,0)- Click D4.
- Type =IFERROR(B4*C4,0) and press Enter.
- Drag the fill handle down.
2 Your turn
Download the practice file. It has new numbers. Open it in Excel (or Google Sheets) and do the same steps.
3 Check your answers
Stuck? Download the solution file and compare it with yours.
Next lab: Sort Sales from High to Low →
Want the theory? Read the Fixes & Errors lessons →
← More Fixes & Errors labs · All lab categories