Advanced lookups
Tiered scales, two-criteria lookups, two-way INDEX + MATCH, XMATCH and CHOOSE.
- The commission scale is in A:B: sales from 0 — 1%, from 10 mln — 2%, from 25 mln — 3.5%, from 50 mln — 5%. In cell F5, find Sardor's commission rate with VLOOKUP approximate match.
- The discount scale is in A:B. In cell F3, calculate the discount amount (in UZS) for order #502: purchase × the scale rate. Find the rate with INDEX and MATCH (1 — approximate match).
- The plan is looked up by manager AND month — one column isn't enough. In cell A2, write a helper key: the manager and the month joined with "-" (e.g. Ali-January).
- The keys in column A are ready. In cell G3, use VLOOKUP to find the plan for the manager in G1 and the month in G2 — build the lookup value the same way as the key.
- A sales matrix: managers in rows, months in columns. In cell B9, find the sales of the manager in B7 for the month in B8 using INDEX and two MATCHes.
- Delivery tariffs: regions in rows, service types in columns. In cell B9, find the price for the region in B7 and the service in B8 using INDEX and two XMATCHes.
- B7 holds a month number (1 — January, 2 — February, 3 — March). In cell B8, use SUM and CHOOSE to total sales of all products for that month.