Problem with VLOOKUP when different cells contain the same data

TheJay

Active Member
Joined
Nov 12, 2014
Messages
364
Office Version
  1. 2019
Platform
  1. Windows
Hello there,

I am having a problem with my worksheet. During testing, everything seemed to be fine, then I realised if there is the same data in any preceding rows, the remaining columns display data from the wrong row.

Can someone please tell me how I get this fixed? I need to have the same data in different rows without VLOOKUP acting up.

Thank you.

 

Excel Facts

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)
Hello there,

I am having a problem with my worksheet. During testing, everything seemed to be fine, then I realised if there is the same data in any preceding rows, the remaining columns display data from the wrong row.

Can someone please tell me how I get this fixed? I need to have the same data in different rows without VLOOKUP acting up.

Thank you.

password ?
 
Upvote 0
What version of Excel are you using?

I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)
 
Upvote 0
What version of Excel are you using?

I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)
I have done as suggested, it's Windows 11 and Office 2019 Professional Plus.
 
Upvote 0
Thanks for that (y)
How about in D4 dragged across
Excel Formula:
=VLOOKUP($C4,$C5:D7,COLUMNS($C:D),FALSE)
 
Upvote 0
Solution
Thank you very much, that looks like it worked properly! How does that change the functionality? I'm trying to understand the difference. I an see it now appears to check the entire column on the sheet but aside from that, I don't know.
 
Upvote 0
It is looking for the value in C4 in C5:C7 for every column & the COLUMNS($C:D) tells it which column to get the answer from.
 
Upvote 0

Forum statistics

Threads
1,213,510
Messages
6,114,048
Members
448,543
Latest member
MartinLarkin

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