Xlookup not working when there are duplicate values?

Mark McInerney

Active Member
Joined
Apr 4, 2012
Messages
281
Office Version
  1. 365
Platform
  1. Windows
Hi Folks - Thanks in advance for looking at this.

When there is a duplication in the sales column, the xlookup returns the first value every time - in the example below the "West" store is not appearing on my list when I use the xlookup formula - is there a way around this without me having to add a helper column to create unique sales values?

1716719577868.png
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
Would e.g. this do the trick:

Excel Formula:
=DROP(REDUCE("",UNIQUE(G6:G10),LAMBDA(a,b,VSTACK(a,FILTER(C6:C10,D6:D10=b)))),1)
 
Upvote 0
Try:
Book1
ABCDEFGHI
1
2
3
4
5SalesStoreRankSalesStore
6North212North
7South722West
8East835Temp
9West247South
10Temp558East
Sheet7
Cell Formulas
RangeFormula
I6:I10I6=INDEX(FILTER(Sales[Sales],Sales[Store]=G6),COUNTIF($G$6:G6,G6))
 
Upvote 0
Another option
Fluff.xlsm
ABCDEFGH
1
2
3
4
5SalesStoreRankSalesStore
6North212North
7South722West
8East835Temp
9West247South
10Temp558East
Data
Cell Formulas
RangeFormula
G6:H10G6=CHOOSECOLS(SORT(C6:D10,2),2,1)
Dynamic array formulas.
 
Upvote 0

Forum statistics

Threads
1,223,227
Messages
6,170,848
Members
452,361
Latest member
d3ad3y3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top