INDEX MATCH vs SUMIFS Query

sgm2

New Member
Joined
Feb 10, 2022
Messages
4
Office Version
  1. 365
Platform
  1. Windows
Hi I'm trying to convert a SUMIFS query into an INDEX MATCH function for golf results. The only columns to consider are Year, Player Name and Position. If it was only numeric a SUMIFS function would do the job and if it was only for one year the INDEX(X:X,MATCH(A1,Y:Y,0)) - or a simple VLOOKUP function would work but the fact that the same names comes up in different years is stumping me. I need to add in an IF statement. For Example you might have:

2021 Rory McIlroy T5
2020 Rory McIlroy 8
2019 Rory McIlroy MC

Any help is appreciated.
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
You could use FILTER since you have 365.
 
Upvote 0
Welcome to the board.

Maybe something like this?

Code:
=TEXTJOIN(", ",TRUE,IF(B1:B4="Rory McIlroy",C1:C4,""))
 
Upvote 0
You could use FILTER since you have 365.
Thanks for the response. I'm not sure I follow though...

I have a list of results for a particular competition for say 12 years. From that list i'm trying to pull the results to a matrix. If the list is say:

2021 Rory McIlroy T5
2021 Jon Rahm 8
2020 Jon Rahm 1
2020 Rory McIlroy T20

I'm looking for a matrix showing:

Rory McIlroy T5 T20
Jon Rahm 8 1

Its easy using a lookup function for each separate year but I'm sure there is a more efficient way considering i'll be looking to update the sheet every year.

Thanks again.
 
Upvote 0
Welcome to the board.

Maybe something like this?

Code:
=TEXTJOIN(", ",TRUE,IF(B1:B4="Rory McIlroy",C1:C4,""))
Thanks for the response.

I'm not sure this would work (see above post) there are multiple rows with "Rory McIlroy" for the different years so how would that function separate them. The easiest way to explain is if there were no text and it was just numeric (and say you replaced MC with 500) a simple SUMIFS(C1:C4,A1:A4,2021,B1:B4,"Rory McIlroy")
 
Upvote 0
My previous suggestion would concatenate across years. If you want the years in separate columns, it sounds like this might be what you're looking for, where it uses the CONCATENATEX DAX function within a pivot table.

See this for more:

 
Upvote 0
My previous suggestion would concatenate across years. If you want the years in separate columns, it sounds like this might be what you're looking for, where it uses the CONCATENATEX DAX function within a pivot table.

See this for more:

Hi, I appreciate the time and help but i'm not quite getting a solution. Would it be possible to email you my sheet for more clarity. I'm sure there will be a simple solution by incorporating an IF statement to an INDEX MATCH.
 
Upvote 0
Book3
ABCDEFGH
1YearNameFinish
22021Rory McIlroyT5Formula Result
32021Jon Rahm8Rory McIlroyT5, T20
42020Jon Rahm1Jon Rahm8, 1
52020Rory McIlroyT20
6
7
8YearNameFinishResultsColumn Labels
92021Rory McIlroyT5Row Labels20202021Grand Total
102021Jon Rahm8Jon Rahm188, 1
112020Jon Rahm1Rory McIlroyT20T5T5, T20
122020Rory McIlroyT20
13
Sheet1
Cell Formulas
RangeFormula
F3:F4F3=TEXTJOIN(", ",TRUE,IF($B$2:$B$5=E3,$C$2:$C$5,""))


A1:C5 has a normal range of cells, E3:E4 have the list of golfers, and F3:F4 has the result of the TEXTJOIN formula.

A8:C12 has the same data, but input as a table. E8:H11 has the output you'd get per the CONCATENATEX DAX formula within a pivot table per the link above.

If neither of those are what you're looking for, please post a sample of what you would like the result to look like.
 
Upvote 0

Forum statistics

Threads
1,214,817
Messages
6,121,720
Members
449,050
Latest member
MiguekHeka

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