Hi Excel Geeks
I am trying to match the first name and surname on one list to a second list of names and if they match to select the cost against the matched name from the first list and add it to the second list - I have attached a sample file to clarify what I am trying to achieve.
The difficulty I have is when two or more people have the same first name - combining the surname has given me an error message and I cannot spot my error.
Please can you help!
Regards
Mel
Hi Mel
I found 3 solutions for you. One uses the SUMIFS. The another used the INDEX+MATCH array formula and the last one is non-array INDEX+MATCH.
Hope this helps.
Hi Sunny
Excellent - I am spoilt for choice with your three solutions.
Regards
Mel
Hi Sunny
Going back to the index and match formulae - if I want to suppress the #N/A from appearing in a cell how do I do it. I have used the ISERROR before and comfortable in using it with 'if statements' - attached the file showing the error message.
Hi Mel
Just wrap your formula with =IFERROR(Your formula,0).This will display a 0 if the formula evaluates to an error.
Example =IFERROR(INDEX('List of names with costs'!$E$5:$E$9,MATCH(1,INDEX(('Names to match and add costs'!B3='List of names with costs'!$B$5:$B$9)*(C3='List of names with costs'!$C$5:$C$9),0),0)),0)
Hope this helps.
Sunny
Hi Sunny
Thank you so much for your help. It is great to have someone like you on the forum.
I thought ISERROR was the commonly used function to suppress errors - I am learning from you every time.
Once again thank you.
Mel
Glad I was able to help
Sunny