Extract a BLANK

billandrew

Well-known Member
Joined
Mar 9, 2014
Messages
743
Good Morning

I am trying to show a blank in the resulting formula instead of a zero. Let me try and explain. I have a the following table (Table 1) in columns A & B.

NameSales
mike12389
mike10254
tom11658
tom20459
robert14523
robert12365
robert10248
george12489
glen45688
larry9999
glen12354

<tbody>
</tbody>

Table 2 -

1st - I am extracting the names vertically using the following formula in cell E2. I am extending the range to allow additional names to be entered.

E2
=IFERROR(INDEX($A$2:$A$20,SMALL(IF(FREQUENCY(IF($A$2:$A$20<>"",MATCH($A$2:$A$20,$A$2:$A$20,0)),ROW($A$2:$A$20)-ROW($A$2)+1),ROW($A$2:$A$20)-ROW($A$2)+1),ROWS($E$2:E2))),"")


2nd - In cell F2 I am extracting the sales for each name using the the following formula =IFERROR(INDEX($B$2:$B$20,SMALL(IF($A$2:$A$20=$E2,ROW($A$2:$A$20)-ROW($A$2)+1),COLUMNS($F2:F2)),ROW($A$2:$A$20)-ROW($A$2)),"")


My issue is the blank cells where no name has yet been established the result is a zero. I'd like to return a blank.

Hope my description is clear enough to interpret.

Thanks

NamesSales1Sales2Sales3Sales4Sales5

<tbody>
</tbody>
 
billandrew,

Thanks for the feedback.

You are very welcome. Glad I could help.

And, come back anytime.
 
Upvote 0

Excel Facts

Why are there 1,048,576 rows in Excel?
The Excel team increased the size of the grid in 2007. There are 2^20 rows and 2^14 columns for a total of 17 billion cells.

Forum statistics

Threads
1,214,784
Messages
6,121,540
Members
449,038
Latest member
Guest1337

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