XLOOKUP practice: preserve missing customers Original fictional practice data · 2026-11-11 · CC BY 4.0 BRIEF The dispatch queue must keep every shipment even when the customer master is incomplete. Create an explicit review label rather than hiding an unmatched shipment. CONTRACT 1. Customer IDs are unique in this case and must match exactly. 2. Every shipment must remain, including the zero-unit shipment. Missing keys receive REVIEW, not a blank or zero. 3. Output shipment_id, region, units in shipment_id order. METHOD Count the five source shipments before a lookup. In Excel import each CSV to its own sheet and use an exact lookup with an explicit missing label. In SQL preserve the shipment side with LEFT JOIN and compare row count and unit total. COMMON MISTAKE An inner join loses S02 and S05 and makes an incomplete dispatch queue look valid. INDEPENDENT CROSS-CHECK Five shipments and 14 units remain. Two shipment keys need master-data review. EXCEL METHOD With shipments on sheet Shipments and customers on Customers, put =XLOOKUP(B2,Customers!$A$2:$A$4,Customers!$B$2:$B$4,"REVIEW",0) in a new region column and fill down. Export only shipment_id,region,units in that order. DELIVER A checked output CSV and a handoff note explaining the exception policy. Use setup.sql in SQLite or import each table CSV into your spreadsheet. expected.csv is the complete reference result; an empty CSV field represents SQL NULL. The browser executes SQLite, not Excel formulas. XLOOKUP is unavailable in Excel 2016 and 2019. Sources for function behavior: https://www.sqlite.org/lang_select.html and https://support.microsoft.com/en-us/excel/functions/xlookup-function (checked 2026-11-11). Rates, dates and policies here are exercise assumptions.