VLOOKUP and XLOOKUP Inventory Guide
VLOOKUP and XLOOKUP Inventory Guide
Formula =VLOOKUP($B20;$I$9:$M$12;2;FALSE)
Anders
Created Date Created by:
08-05-2020 Serdar
ALT 1: XLOOKUP
Inventory Table Lookup Table
ProductID Name LocationID Shelf Bin Quantity ProductID ProductNumber Name SafetyStockLevel ReorderPoint
1 Adjustable Race 1 A 1 408 1 AR-5381 Adjustable Race 1000 750
1 Adjustable Race 6 B 5 324 2 BA-8327 Bearing Ball 1000 750
1 Adjustable Race 50 A 5 353 3 BE-2349 BB Ball Bearing 800 600
2 Bearing Ball 1 A 2 427 4 BE-2908 Headset Ball Bearings 800 600
2 Bearing Ball 6 B 1 318 316 BL-2036 Blade 800 600
2 Bearing Ball 50 A 6 364 317 CA-5965 LL Crankarm 500 375
3 BB Ball Bearing 1 A 7 585
3 BB Ball Bearing 6 B 9 443 XLOOKUP is our top alternative to VLOOKUP. It is simple,
3 BB Ball Bearing 50 A 10 324 powerful, can do error handling, and do exact matching. All in 1
4 Headset Ball Bearings 1 A 6 512 formula!
4 Headset Ball Bearings 6 B 10 422
4 Headset Ball Bearings 50 A 11 388
316 Blade 5 A 11 532
316 Blade 10 B 1 388
316 Blade 50 B 8 441
317 LL Crankarm 1 C 1 283
317 LL Crankarm 5 A 1 158
317 LL Crankarm 50 A 21 152
Formula: =XLOOKUP([@ProductID];LookupTable3[ProductID];LookupTable3[Name];"")
Anders
Created Date Created by:
08-05-2020 Serdar
Data source: Microsoft AdventureWorks
Formula: =VLOOKUP($B26;$I$9:$M$12;2;FALSE)
Anders
Created Date Created by:
08-05-2020 Serdar
Data source: Microsoft AdventureWorks
VLOOKUP TABLE
Inventory Table Lookup Table
ProductID Name LocationID Shelf Bin Quantity ProductID ProductNumber Name SafetyStockLevel ReorderPoint
1 Adjustable Race 1 A 1 408 1 AR-5381 Adjustable Race 1000 750
1 Adjustable Race 6 B 5 324 2 BA-8327 Bearing Ball 1000 750
1 Adjustable Race 50 A 5 353 3 BE-2349 BB Ball Bearing 800 600
2 Bearing Ball 1 A 2 427 4 BE-2908 Headset Ball Bearings 800 600
2 Bearing Ball 6 B 1 318 316 BL-2036 Blade 800 600
2 Bearing Ball 50 A 6 364 317 CA-5965 LL Crankarm 500 375
3 BB Ball Bearing 1 A 7 585
3 BB Ball Bearing 6 B 9 443 In this example, we created our basic VLOOKUP formula using
3 BB Ball Bearing 50 A 10 324 tables. It is recommended that you use tables over ranges to
4 Headset Ball Bearings 1 A 6 512 mitigate of selecting missing ranges in the formulas.
4 Headset Ball Bearings 6 B 10 422 Moreover, formulas including table referances are easier to
4 Headset Ball Bearings 50 A 11 388 read.
316 Blade 5 A 11 532
316 Blade 10 B 1 388
316 Blade 50 B 8 441
317 LL Crankarm 1 C 1 283
317 LL Crankarm 5 A 1 158
317 LL Crankarm 50 A 21 152
Formula =VLOOKUP([@ProductID];Lookup_Table;3;FALSE)
Anders
Created Date Created by:
08-05-2020 Serdar
Data source: Microsoft AdventureWorks
VLOOKUP DYNAMIC
Inventory Table Lookup Table
ProductID Name LocationID Shelf Bin Quantity ProductID Name ProductNumber SafetyStockLevel ReorderPoint
1 Adjustable Race 1 A 1 408 1 Adjustable Race AR-5381 1000 750
1 Adjustable Race 6 B 5 324 2 Bearing Ball BA-8327 1000 750
1 Adjustable Race 50 A 5 353 3 BB Ball Bearing BE-2349 800 600
2 Bearing Ball 1 A 2 427 4 Headset Ball Bearings BE-2908 800 600
2 Bearing Ball 6 B 1 318 316 Blade BL-2036 800 600
2 Bearing Ball 50 A 6 364 317 LL Crankarm CA-5965 500 375
3 BB Ball Bearing 1 A 7 585
3 BB Ball Bearing 6 B 9 443 In this example, we created our basic VLOOKUP formula using
3 BB Ball Bearing 50 A 10 324 tables. It is recommended that you use tables over ranges to
4 Headset Ball Bearings 1 A 6 512 mitigate of selecting missing ranges in the formulas. Moreover,
4 Headset Ball Bearings 6 B 10 422 formulas including table referances are easier to read.
4 Headset Ball Bearings 50 A 11 388
316 Blade 5 A 11 532
316 Blade 10 B 1 388
316 Blade 50 B 8 441
317 LL Crankarm 1 C 1 283
317 LL Crankarm 5 A 1 158
317 LL Crankarm 50 A 21 152
Formula: =VLOOKUP([@ProductID];LookupTable1;COLUMN(LookupTable1[[#Headers];[Name]])-COLUMN(LookupTable1[[#Headers];[ProductID]])+1;FALSE)
Anders
Created Date Created by:
08-05-2020 Serdar
Data source: Microsoft AdventureWorks
Formula: =VLOOKUP([@ProductID];LookupTable2;COLUMN(LookupTable2[[#Headers];[Name]])-COLUMN(LookupTable2[[#Headers];[ProductID]])+1;FALSE)
Anders
Created Date Created by:
08-05-2020 Serdar
Data source: Microsoft AdventureWorks
Formula: =XLOOKUP([@ProductID];LookupTable4[ProductID];LookupTable4[Name];"")
Anders
Created Date Created by:
08-05-2020 Serdar
Data source: Microsoft AdventureWorks
Formula: =XLOOKUP(C$8;LookupTable5[#Headers];XLOOKUP($B26;LookupTable5[ProductID];LookupTable5))
Anders
Created Date Created by:
08-05-2020 Serdar
Data source: Microsoft AdventureWorks
ALT3: INDEX-MATCH
Inventory Table Lookup Table
ProductID Name LocationID Shelf Bin Quantity ProductID ProductNumber Name SafetyStockLevel ReorderPoint
1 Adjustable Race 1 A 1 408 1 AR-5381 Adjustable Race 1000 750
1 Adjustable Race 6 B 5 324 2 BA-8327 Bearing Ball 1000 750
1 Adjustable Race 50 A 5 353 3 BE-2349 BB Ball Bearing 800 600
2 Bearing Ball 1 A 2 427 4 BE-2908 Headset Ball Bearings 800 600
2 Bearing Ball 6 B 1 318 316 BL-2036 Blade 800 600
2 Bearing Ball 50 A 6 364 317 CA-5965 LL Crankarm 500 375
3 BB Ball Bearing 1 A 7 585
3 BB Ball Bearing 6 B 9 443
INDEX MATCH is our second best choice to replace VLOOKUP.
3 BB Ball Bearing 50 A 10 324
Particularly, it is very useful for users with no Office365 subscription.
4 Headset Ball Bearings 1 A 6 512
4 Headset Ball Bearings 6 B 10 422
4 Headset Ball Bearings 50 A 11 388
316 Blade 5 A 11 532
316 Blade 10 B 1 388
316 Blade 50 B 8 441
317 LL Crankarm 1 C 1 283
317 LL Crankarm 5 A 1 158
317 LL Crankarm 50 A 21 152
Formula: =INDEX(LookupTable6;MATCH([@ProductID];LookupTable6[ProductID];0);MATCH(B$8;LookupTable6[#Headers];0))
Anders
Created Date Created by:
08-05-2020 Serdar
Data source: Microsoft AdventureWorks
ALT 4: LOOKUP
Inventory Table Lookup Table
ProductID Name LocationID Shelf Bin Quantity ProductID ProductNumber Name SafetyStockLevel ReorderPoint
1 Adjustable Race 1 A 1 408 1 AR-5381 Adjustable Race 1000 750
1 Adjustable Race 6 B 5 324 2 BA-8327 Bearing Ball 1000 750
1 Adjustable Race 50 A 5 353 3 BE-2349 BB Ball Bearing 800 600
2 Bearing Ball 1 A 2 427 4 BE-2908 Headset Ball Bearings 800 600
2 Bearing Ball 6 B 1 318 316 BL-2036 Blade 800 600
2 Bearing Ball 50 A 6 364 317 CA-5965 LL Crankarm 500 375
3 BB Ball Bearing 1 A 7 585
3 BB Ball Bearing 6 B 9 443
3 BB Ball Bearing 50 A 10 324 LOOKUP formula is another alternative to VLOOKUP! However, you
4 Headset Ball Bearings 1 A 6 512 can't do an exact match with LOOKUP. Thus, you may want to
4 Headset Ball Bearings 6 B 10 422 avoid using it as a replacement of VLOOKUP inc ase your data is not
4 Headset Ball Bearings 50 A 11 388 in the right order.
316 Blade 5 A 11 532
316 Blade 10 B 1 388
316 Blade 50 B 8 441
317 LL Crankarm 1 C 1 283
317 LL Crankarm 5 A 1 158
317 LL Crankarm 50 A 21 152
Formula: =LOOKUP([@ProductID];LookupTable7[ProductID];LookupTable7[Name])
Anders
Created Date Created by:
08-05-2020 Serdar
Data source: Microsoft AdventureWorks
ALT 5: LOOKUP-2
Inventory Table Lookup Table
ProductID Name LocationID Shelf Bin Quantity ProductID ProductNumber Name SafetyStockLevel ReorderPoint
1 Adjustable Race 1 A 1 408 1 AR-5381 Adjustable Race 1000 750
1 Adjustable Race 6 B 5 324 2 BA-8327 Bearing Ball 1000 750
1 Adjustable Race 50 A 5 353 3 BE-2349 BB Ball Bearing 800 600
2 Bearing Ball 1 A 2 427 4 BE-2908 Headset Ball Bearings 800 600
2 Bearing Ball 6 B 1 318 316 BL-2036 Blade 800 600
2 Bearing Ball 50 A 6 364 317 CA-5965 LL Crankarm 500 375
3 BB Ball Bearing 1 A 7 585
3 BB Ball Bearing 6 B 9 443
3 BB Ball Bearing 50 A 10 324 Using LOOKUP(2,1/...) is another method to VLOOKUP. However,
4 Headset Ball Bearings 1 A 6 512 this still doesn't resolve the approximation issue. LOOKUP is a great
4 Headset Ball Bearings 6 B 10 422 formula to use in approximations but not as much useful to use for
4 Headset Ball Bearings 50 A 11 388 exact matching.
316 Blade 5 A 11 532
316 Blade 10 B 1 388
316 Blade 50 B 8 441
317 LL Crankarm 1 C 1 283
317 LL Crankarm 5 A 1 158
317 LL Crankarm 50 A 21 152
Formula: =LOOKUP(2;1/(LookupTable8[ProductID]=[@ProductID]);LookupTable8[Name])
Anders
Created Date Created by:
08-05-2020 Serdar
ALT 6: FILTER
Inventory Table Lookup Table
ProductID Name LocationID Shelf Bin Quantity ProductID ProductNumber Name SafetyStockLevel ReorderPoint
1 Adjustable Race 1 A 1 408 1 AR-5381 Adjustable Race 1000 750
1 Adjustable Race 6 B 5 324 2 BA-8327 Bearing Ball 1000 750
1 Adjustable Race 50 A 5 353 3 BE-2349 BB Ball Bearing 800 600
2 Bearing Ball 1 A 2 427 4 BE-2908 Headset Ball Bearings 800 600
2 Bearing Ball 6 B 1 318 316 BL-2036 Blade 800 600
2 Bearing Ball 50 A 6 364 317 CA-5965 LL Crankarm 500 375
3 BB Ball Bearing 1 A 7 585
3 BB Ball Bearing 6 B 9 443
FILTER is a new Office365 formula. You can use filter to replace
3 BB Ball Bearing 50 A 10 324
VLOOKUP. It is easier to use and read.
4 Headset Ball Bearings 1 A 6 512
4 Headset Ball Bearings 6 B 10 422
4 Headset Ball Bearings 50 A 11 388
316 Blade 5 A 11 532
316 Blade 10 B 1 388
316 Blade 50 B 8 441
317 LL Crankarm 1 C 1 283
317 LL Crankarm 5 A 1 158
317 LL Crankarm 50 A 21 152
Formula =FILTER(LookupTable9[Name];LookupTable9[ProductID]=[@ProductID];"")
Anders
Created Date Created by:
08-05-2020 Serdar
Formula: =OFFSET(INDEX(Lookup_Table13[#Headers];;1);MATCH([@ProductID];Lookup_Table13[ProductID];0);MATCH(C$8;Lookup_Table13[#Headers];0)-1)
Anders
Created Date Created by:
Data source: Microsoft AdventureWorks 08-05-2020 Serdar
Formula: =INDIRECT(ADDRESS(ROW($I$8)+MATCH([@ProductID];Lookup_Table14[ProductID];0);MIN(COLUMN(Lookup_Table14[#Headers]))+MATCH($C$8;Lookup_Table14[#Headers];0)-1))