Vlookup Only The First Lookup Value

anconavince

New Member
Joined
Nov 12, 2019
Messages
6
Hello,
I think I have a fairly simple problem (but one I can't fix). Column A of sheet "Model" has hundreds of thousands of account numbers, many of which are duplicates. I need to vlookup based on those account numbers to return data from Column B of sheet "Cost", but I only want to return data for the first occurrence of each account number in sheet "Model".
I've tried a nested IF formula but can't quite get it to work. Thank you in advance for any help.
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Hi & welcome to MrExcel.
How about something like
=IF(COUNTIF(A$2:A2,A2)=1,your Vlookup formula,"")
 
Upvote 0
Hi Fluff, thank you. I now realize I should come up with a better username haha.

So this formula works to pull my vlookup, but it doesn't quite eliminate the issue I'm having. My goal is to only return column B of sheet "Cost" for the first of multiple account numbers in column A of "Model" so that I can pivot without duplicate cost data. Does that make sense?
 
Upvote 0
That formula will only run the vlookup the first time an account appears, all subsequent times the formula will return ""
 
Upvote 0

Forum statistics

Threads
1,224,813
Messages
6,181,117
Members
453,021
Latest member
Justyna P

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