Index and Match is returning #VALUE

Sean15

Well-known Member
Joined
Jun 25, 2005
Messages
700
Office Version
  1. 2010
Platform
  1. Windows

Excel 2010
ABC
18First NameLast NameAmt
19JohnJohnson15,000.00
20SmithSmithson850.00
21JamesJemson17,520.00
22kenJemson16,500.00
23
24John Johnson[URL=https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=VALUE]#VALUE[/URL] !
25Johnson, John[URL=https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=VALUE]#VALUE[/URL] !
Sheet1
Cell Formulas
RangeFormula
B24=INDEX(C$19:C$22,MATCH(A24,A$19:A$22&" "&B$19:B$22))
B25=INDEX(C$19:C$22,MATCH(A25,B$19:B$22&", "&A$19:A$22))


Index and Match is returning #VALUE . Could you help me fix formula please?


Regards,

Sean
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
Thanks. I am getting expected and unexpected values. Please see below.



Excel 2010
ABC
18First NameLast NameAmt
19JohnJohnson15,000.00
20SmithSmithson850.00
21JamesJemson17,520.00
22kenJemson16,500.00
23
24John Johnson15,000.00
25Smith Smithson850.00
26James Jemson#N/A
27Johnson, John#N/A
Sheet1
Cell Formulas
RangeFormula
B24{=INDEX(C$19:C$22,MATCH(A24,A$19:A$22&" "&B$19:B$22))}
B25{=INDEX(C$19:C$22,MATCH(A25,A$19:A$22&" "&B$19:B$22))}
B26{=INDEX(C$19:C$22,MATCH(A26,A$19:A$22&" "&B$19:B$22))}
B27{=INDEX(C$19:C$22,MATCH(A27,B$19:B$22&", "&A$19:A$22))}
Press CTRL+SHIFT+ENTER to enter array formulas.
 
Upvote 0
It also needs to be an 'Exact Match', the 3rd argument in Match should be 0

=INDEX(C$19:C$22,MATCH(A24,A$19:A$22&" "&B$19:B$22,0))
 
Upvote 0
Thanks, I see how this works now. But I still can't get Johnson, John to work.


Excel 2010
AB
27Johnson, John#N/A
Sheet1
Cell Formulas
RangeFormula
B27{=INDEX(C$19:C$22,MATCH(A27,B$19:B$22&", "&A$19:A$22,0))}
Press CTRL+SHIFT+ENTER to enter array formulas.
 
Upvote 0
Sean15, Good afternoon.

Jonmo1, hi and greetings from Brazil.

Sean15, maybe you can use an anternative formula that can solve both cases with one formula.

Try to use:

ARRAY FORMULA

Code:
=IF(ISERROR(SEARCH(",",[B]A24[/B])),INDEX($C$19:$C$22,MATCH([B]A24,[/B] $A$19:$A$22 & " " & $B$19:$B$22, 0)),INDEX($C$19:$C$22;MATCH([B]A24[/B], $B$19:$B$22& ", " & $A$19:$A$22, 0)))

Please, tell us if it worked as you desire.

I hope it helps.
 
Upvote 0
@ Marcílio_Lobão

XL message pops up: formula contains an error.
 
Upvote 0
Sean15,

Excuse-me.
I typed wrongly a SEMICOLON instead a COMMA.

Try to use:

Code:
=IF(ISERROR(SEARCH(",",[B]A24[/B])),INDEX($C$19:$C$22,MATCH([B]A24,[/B] $A$19:$A$22 & " " & $B$19:$B$22, 0)),INDEX($C$19:$C$22[SIZE=5][COLOR=#ff0000][B],[/B][/COLOR][/SIZE]MATCH([B]A24[/B], $B$19:$B$22& ", " & $A$19:$A$22, 0)))

I hope it helps.
 
Upvote 0
@ Marcílio_Lobão

Looking good, but I can't figure out why it's bombing on the name Johnson.



Excel 2010
ABC
18First NameLast NameAmt
19JohnJohnson15,000.00
20SmithSmithson850.00
21JamesJemson17,520.00
22kenJemson16,500.00
23
24John Johnson#N/A
25Smith Smithson850.00
26James Jemson17,520.00
27Johnson, John#N/A
28ken Jemson16,500.00
Sheet1
Cell Formulas
RangeFormula
B24{=IF(ISERROR(SEARCH(",",A24)),INDEX($C$19:$C$22,MATCH(A24, $A$19:$A$22 & " " & $B$19:$B$22, 0)),INDEX($C$19:$C$22,MATCH(A24, $B$19:$B$22& ", " & $A$19:$A$22, 0)))}
B25{=IF(ISERROR(SEARCH(",",A25)),INDEX($C$19:$C$22,MATCH(A25, $A$19:$A$22 & " " & $B$19:$B$22, 0)),INDEX($C$19:$C$22,MATCH(A25, $B$19:$B$22& ", " & $A$19:$A$22, 0)))}
B26{=IF(ISERROR(SEARCH(",",A26)),INDEX($C$19:$C$22,MATCH(A26, $A$19:$A$22 & " " & $B$19:$B$22, 0)),INDEX($C$19:$C$22,MATCH(A26, $B$19:$B$22& ", " & $A$19:$A$22, 0)))}
B27{=IF(ISERROR(SEARCH(",",A27)),INDEX($C$19:$C$22,MATCH(A27, $A$19:$A$22 & " " & $B$19:$B$22, 0)),INDEX($C$19:$C$22,MATCH(A27, $B$19:$B$22& ", " & $A$19:$A$22, 0)))}
B28{=IF(ISERROR(SEARCH(",",A28)),INDEX($C$19:$C$22,MATCH(A28, $A$19:$A$22 & " " & $B$19:$B$22, 0)),INDEX($C$19:$C$22,MATCH(A28, $B$19:$B$22& ", " & $A$19:$A$22, 0)))}
Press CTRL+SHIFT+ENTER to enter array formulas.



Sean
 
Upvote 0

Forum statistics

Threads
1,216,762
Messages
6,132,575
Members
449,737
Latest member
naes

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