Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 07-20-2021, 07:11 AM
mance006 mance006 is offline Vlookup help Windows 10 Vlookup help Office 2016
Novice
Vlookup help
 
Join Date: Jul 2021
Posts: 1
mance006 is on a distinguished road
Default Vlookup help

Hello, I am new to excel and any help would be greatly appreciated. I have 2 sheets with 2 columns each. First column in sheet 1 is a name, and second column is an ID number. Second sheet is also a name, and ID numbers.



I need the ID numbers that are on sheet 1 copied to sheet 2 if the names are on both lists. How can I go about doing this?
Reply With Quote
  #2  
Old 07-20-2021, 09:35 AM
Purfleet Purfleet is offline Vlookup help Windows 10 Vlookup help Office 2019
Expert
 
Join Date: Jun 2020
Location: Essex
Posts: 345
Purfleet is a splendid one to beholdPurfleet is a splendid one to beholdPurfleet is a splendid one to beholdPurfleet is a splendid one to beholdPurfleet is a splendid one to beholdPurfleet is a splendid one to beholdPurfleet is a splendid one to behold
Default

Can you post an example workbook? I will be several million times eaiser to show you
Reply With Quote
  #3  
Old 08-04-2021, 03:54 PM
Dominique Gascon Dominique Gascon is offline Vlookup help Windows 10 Vlookup help Office 2019
Novice
 
Join Date: Jan 2021
Posts: 2
Dominique Gascon is on a distinguished road
Default

Assuming that the first list is in sheet 1 with names in col A and ID in col B, and the same in sheet 2 for the 2nd list,

then to "=VLOOKUP(A2;Sheet1!A:B;2;0)" will return the ID in sheet 1 of the name in cell A2 of sheet 2.
You need to put a 0 as the 4th parameter to force an exact match.
If there are 2 identical names in sheet 1, the formula will return the first one.


If a name is not found, it will return NA# that you'll need to deal with.


I searched the whole column, but you may want to use a named range or dynamic range to restrict the search, but I don't think that it does make much difference performance wise.



see attached example.
Attached Files
File Type: xlsx Vlookup.xlsx (15.3 KB, 6 views)
Reply With Quote
  #4  
Old 08-05-2021, 03:19 AM
Pecoflyer's Avatar
Pecoflyer Pecoflyer is offline Vlookup help Windows 7 64bit Vlookup help Office 2010
Expert
 
Join Date: Nov 2011
Location: Brussels Belgium
Posts: 2,766
Pecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant future
Default

Quote:
Originally Posted by Dominique Gascon View Post
I searched the whole column, but you may want to use a named range or dynamic range to restrict the search, but I don't think that it does make much difference performance wise.

see attached example.

Or simply use the Excel Table feature
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Tell me which place the vlookup was successful (within a nested vlookup) Izzii0x Excel 2 07-18-2019 10:29 PM
How can I return Vlookup only if Specific Criteria is met in 1 column of the Vlookup Array EcommDOC Excel 7 01-22-2018 11:00 AM
Vlookup help Vlookup Missthingy Excel 1 02-10-2017 09:59 AM
Vlookup help IF and VLOOKUP SBMC Excel 1 11-07-2012 10:24 AM
Vlookup ibrahimaa Excel 8 01-03-2012 09:32 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 10:26 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft