# Formula to find label for top five values using INDEX / AGGREGATE

1. ## Formula to find label for top five values using INDEX / AGGREGATE

Good morning,

I have a pivot table with phone call and email audit scores. I want to automatically find the top five scores per month. So I can use an =LARGE sum for the number, but then finding the associated label is causing me issues.
I can't use a vlookup to the value because the values can be identical. I found a YouTube video which shows a workaround, but I've done something wrong as my formula is finding the wrong label for the value.

I've attached a spreadsheet with my pivot which shows the label in column A (e.g. Greeting), and the score for email and phone in columns B and C. The two adjacent tables show the top five issues for phone and email (or should be), so next month I can refresh my pivot and hey presto! The tables update.

Jemma

2. ## Re: Formula to find label for top five values using INDEX / AGGREGATE

No file attached.

Attach a sample workbook (not image).

Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate.

Make sure your desired results are shown, mock them up manually if necessary.

Remember to desensitize the data.

Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.

3. ## Re: Formula to find label for top five values using INDEX / AGGREGATE

f3=INDEX(\$A\$5:\$A\$48,MATCH(LARGE(INDEX(\$B\$5:\$B\$48+1/ROW(\$B\$5:\$B\$48),0),\$E3),INDEX(\$B\$5:\$B\$48+1/ROW(\$B\$5:\$B\$48),0),0))
j3=INDEX(\$A\$5:\$A\$48,MATCH(LARGE(INDEX(\$C\$5:\$C\$48+1/ROW(\$C\$5:\$C\$48),0),\$I3),INDEX(\$C\$5:\$C\$48+1/ROW(\$C\$5:\$C\$48),0),0))
Tryt this and copy towards down

4. ## Re: Formula to find label for top five values using INDEX / AGGREGATE

@nflsales - you, are a legend. It works!

Thank you

There are currently 1 users browsing this thread. (0 members and 1 guests)