how to create table of unique values with multiple categories(columns to match)

aggie24193

New Member
Joined
Nov 2, 2017
Messages
14
Hello All,
I have been searching to no avail.
I need a formula that lets me create a list of unique values but that has two columns. The first column has multiple categories like fruits and vegetables, and the second column has different kinds. Both columns currently have data that repeats. I understand how to get a single columns of unique values, but not multiple based on the first one.

A good example of where I am starting can be found here: https://www.extendoffice.com/documents/excel/4032-excel-dynamic-list-of-unique-values.html
But now let's pretend I have a column in front of the fruit one called produce and it lists fruit/vegetable and assigns the various values to it.

I hope I am being clear.
I want something that looks like:

Fruit Apple
Fruit Orange
Fruit Banana
Vegetable Squash
Vegetable Zucchini

ETC...

I am trying to use this formula to start: =IFERROR(INDEX($B$2:$B$9, MATCH(0,COUNTIF($D$1:D1, $B$2:$B$9), 0)),"")
 

Excel Facts

Create a Pivot Table on a Map
If your data has zip codes, postal codes, or city names, select the data and use Insert, 3D Map. (Found to right of chart icons).
How about this formula below. It is an array formula to you have to hit Ctrl+Shift+Enter.

Code:
=IFERROR(INDEX($A$2:$A$9&"-"&$B$2:$B$9,MATCH(0,COUNTIF($D$1:D1,$A$2:$A$9&"-"&$B$2:$B$9),0)),"")
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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