How to return multiple headings

CG2018

New Member
Joined
Aug 20, 2018
Messages
3
Hi,
I have been able to use the formula below, to return a catogoery when product and type is selected i.e Item 1 B, returns Cat 2.

[TABLE="width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD][/TD]
[TD]Cat 1[/TD]
[TD]Cat 2[/TD]
[TD]Cat 3[/TD]
[TD]Cat 4[/TD]
[TD]Cat 5[/TD]
[TD]Cat 6[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]Item 1[/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]Item 2[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]A[/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD]Item 3[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]C[/TD]
[TD]C[/TD]
[TD]E[/TD]
[TD]F[/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]6[/TD]
[TD]Product[/TD]
[TD]Item 1[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]7[/TD]
[TD]Type[/TD]
[TD]B[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]8[/TD]
[TD]Result[/TD]
[TD]Cat 2[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]

In cell B8 i have the formula :
=INDEX(B1:G1,,MATCH(B7,INDEX(A2:G4,MATCH(B6,A2:A4,0),0)))

I am now failing to modify this to return multiple cat's i.e Item 3, C to return Cat 1, Cat 3, Cat 4.

help please

Thank you

Colin
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.
Hi,
try maybe array formula in B8 (Ctrl+Shift+Enter) and fill down:
Code:
=INDEX($A$1:$G$1,SMALL(IF(OFFSET($B$1:$G$1,RIGHT($B$6,1)*1,0,1,7)=$B$7,COLUMN($B$1:$G$1),""),ROW(A1)))
Best regards... :)
 
Upvote 0
Hi,
thank you for the quick response, i have tried that. It only returns one result, im looking for the Cell to return all the cats which have type C, so for item 3 it should be three results.
 
Upvote 0
OK,
try to use above Formula in Cells B9, B10... If You want to have all Cats in one Cell, better will be VBA Code, I think... :)
 
Upvote 0
Here is another option:
This is an array function that must be entered with CTRL-SHIFT-ENTER.
Drag formula across columns as needed.
Excel Workbook
ABCDEFG
1Cat 1Cat 2Cat 3Cat 4Cat 5Cat 6
2Item 1ABCDEF
3Item 2BCDEFA
4Item 3CDCCEF
5
6ProductItem 3
7TypeC
8ResultCat 1Cat 3Cat 4
Sheet
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,183
Members
453,020
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