1
00:00:00,080 --> 00:00:04,777
A simple lookup of WX-10 finds East at eighteen dollars, yet

2
00:00:04,777 --> 00:00:07,908
the request is for West at twenty-four.

3
00:00:07,908 --> 00:00:11,431
These are legitimate location prices, not accidental duplicate rows.

4
00:00:11,431 --> 00:00:15,737
We will pair the SKU with the location and check that

5
00:00:15,737 --> 00:00:18,085
each request returns its own price.

6
00:00:18,685 --> 00:00:24,479
Open location-price-practice.csv in a workbook copy and read both WX-10 rows.

7
00:00:24,479 --> 00:00:28,728
XLOOKUP searches its lookup range from the first item by default,

8
00:00:28,728 --> 00:00:32,591
so searching only the SKU column returns the East price.

9
00:00:32,591 --> 00:00:36,840
A valid-looking number can still be the wrong business answer.

10
00:00:37,440 --> 00:00:39,042
Put Key in E1.

11
00:00:39,042 --> 00:00:43,047
In E2 enter =A2&"|"&B2 and fill it to E5.

12
00:00:43,047 --> 00:00:48,254
The vertical bar separates SKU from Location so the combined text remains readable.

13
00:00:48,254 --> 00:00:52,660
Make sure the source fields do not contain that delimiter before

14
00:00:52,660 --> 00:00:55,063
using this pattern on real data.

15
00:00:55,663 --> 00:00:59,351
Type WX-10 in G2 and West in G3.

16
00:00:59,351 --> 00:01:03,859
In G4 enter the XLOOKUP that joins those two inputs, searches

17
00:01:03,859 --> 00:01:08,776
E2 through E5, and returns the aligned price in D2 through D5.

18
00:01:08,776 --> 00:01:13,284
Its exact-match result should be twenty-four dollars, not eighteen.

19
00:01:13,884 --> 00:01:18,530
Change G3 from West to East while leaving G2 as WX-10.

20
00:01:18,530 --> 00:01:22,401
The result must switch from twenty-four to eighteen dollars.

21
00:01:22,401 --> 00:01:26,272
Restore West and the twenty-four-dollar result should return.

22
00:01:26,272 --> 00:01:30,918
This two-way test proves the location field actually controls the lookup.

23
00:01:31,518 --> 00:01:35,450
A combined key solves this practice case only because each

24
00:01:35,450 --> 00:01:37,810
SKU-and-location pair appears once.

25
00:01:37,810 --> 00:01:42,529
If a real file has two WX-10 West rows, XLOOKUP still

26
00:01:42,529 --> 00:01:44,102
returns a first match.

27
00:01:44,102 --> 00:01:49,607
Count the combined key and decide which record is authoritative before publishing a price.
