Forum Discussion
Pull member ID number from sheet 2 into sheet one if the name matches?
Thank you for the sample workbook.
This is the formula for the sample:
=XLOOKUP(C2:C6&D2:D6,'Whole List'!C2:C11&'Whole List'!D2:D11,'Whole List'!A2:A11,"")
Make certain the ranges specified in the XLOOKUP are of equal length. If one column is longer than another, it will result in a #VALUE error.
- Patrick2788Jul 25, 2023Silver Contributor
You'll have to use VLOOKUP-CHOOSE then:
=VLOOKUP(C2&D2,CHOOSE({1,2},'Whole List'!$C$2:$C$11&'Whole List'!$D$2:$D$11,'Whole List'!$A$2:$A$11),2,0)- BrattyBlondeJul 25, 2023Copper Contributor
Patrick2788 Now I'm just getting a #N/A error.. and when I edit the 11's to be 2000 (just in case - current count is actually 1077 but expected to grow) I get the same error. Clicked the little error <!> button and evaluated each step - the CHOOSE { } portion puts the first member's name from the Whole List over and over with each different member number. Guessing that's why it won't work, but not sure how to make it read the whole list instead of getting stuck on the first one. Just to avoid confusion, I made the formula:
=VLOOKUP(C2&D2,CHOOSE({1,2},'Whole List'!$C$2:$C$2000&'Whole List'!$D$2:$D$2000,'Whole List'!$A$2:$A$2000),2,0)- Patrick2788Jul 25, 2023Silver ContributorIt's difficult to say without seeing source data. It could be additional characters in the cells being looked up or the table array. It may be worth using LEN function on a cell to determine how many characters are present in a given cell.
- SergeiBaklanJul 25, 2023Diamond Contributor
It shall work on Excel 2021 as well.
- BrattyBlondeJul 25, 2023Copper Contributor
SergeiBaklan This is an older machine running 2016 apparently
- SergeiBaklanJul 25, 2023Diamond Contributor
Thank you. That's better to mention from very beginning. Majority of answers, if version is not mentioned, assume it is 365 used.