Creating Summary Report in another Worksheet

zrwolf

Board Regular
Joined
Aug 31, 2004
Messages
62
I have an excel worksheet that stores hardware information for a particular job. Hardware is listed by type in columns. There are almost always duplicate listings in a given column (This is neccessary). What I would like to do is to have some summary type information (Part and Qty) on a separate worksheet. I have provided a sample of a column on my existing sheet and what I would like to see on another sheet.

Existing Sheet:

Hardware Type #1 | Hardware Type #2
A1 | Z9
A1 | Z9
A1 | Z9
A2 | Z10
A1 | Z9


New Summary Sheet:

Type#1
A1 | 4
A2 | 1

Type#2
Z9 | 4
Z10 | 1

Any advice is much apprechiated. I am fairly new to excel and VBA but am learning with your help!

-Zack
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes
Let's assume you have the sample data in A1:B6. You can very simply count the occurrences of a particular Type using the formula =COUNTIF("A1",$A$2:$A$6).
If you have a large number of Hardware Types, you can create a list of unique types with Data -> Filter -> Advanced Filter, and select the "Unique records only" checkbox, then substitute "A1" in the formula above with a reference to that list.
VBA will help if you want this summary to update automatically with every change, but it's simple enough to update periodically by hand that you may not want to bother.
HTH :) HAND
 
Upvote 0
I don't want a list of just unique types, I want to create a list the contains one entry for each different type. Then I want to count how many of each type there were. Sorry, I know the verbage is a little strange. Hopefully this example will clarify.

So if my original list is:
A
A
A
B
B
A
B
X
X
Y

I want my new list to be:
A 4
B 3
X 2
Y 1

I would also love for this to update automatically if that isn't extremely difficult.
 
Upvote 0
Like this?
Book2
ABCD
1AA4
2AB3
3AX2
4BY1
5B
6A
7B
8X
9X
10Y
Sheet1

create a list of unique types with Data -> Filter -> Advanced Filter, and select the "Unique records only" checkbox
was included as an easy way to get the values in C1:C4 above, which then serve as the criteria for the formulae in D1:D4.

As far as updating, the Countif formula will recalculate any changes to the existing table, but if you extend that table - say you add entries at rows 11, 12, 13 ... - you'll need then to update the formula to reflect the new extent of the table. You may be able to forego this by setting the count range to the bottom of your sheet, or some other arbitrarily distant point.
Also, adding new unique values - e.g. "C" or "Z" - will require you to update the criteria table and copy the Countif formula.
I don't know how large your data set is, or if you'll need to consider the above factors at all. This was the quickest and simplest solution to your problem as stated. If you're updating this list every day, adding new rows of data and new unique parts, it may be worth spending a little more time at the outset.
 
Upvote 0
Hi Zack,

A Pivot table is the easiest way to deal with this.

Have a look at this..
Book1
ABCDEFGH
1HW1HW2Type#1Type#2
2A1Z9CountofHW1CountofHW2
3A1Z9HW1TotalHW2Total
4A1Z9A14Z101
5A2Z10A21Z94
6A1Z9GrandTotal5GrandTotal5
7
Sheet1


Kris
 
Upvote 0
zrwolf said:
I don't want a list of just unique types, I want to create a list the contains one entry for each different type. Then I want to count how many of each type there were. Sorry, I know the verbage is a little strange. Hopefully this example will clarify.

So if my original list is:
A
A
A
B
B
A
B
X
X
Y

I want my new list to be:
A 4
B 3
X 2
Y 1

I would also love for this to update automatically if that isn't extremely difficult.
aaDistinctListAndCount zrwolf.xls
ABCDEF
14
2Item0DistinctItemsCount
3A1A4
4A B3
5A X2
6B2Y1
7B   
8A   
9B   
10X3
11X 
12Y4
13
Sheet1


Formulas...

B2 must house a 0.

B3, copied down:

=IF((A3<>"")*ISNA(MATCH(A3,$A$2:A2,0)),LOOKUP(9.99999999999999E+307,$B$2:B2)+1,"")

E1:

=LOOKUP(9.99999999999999E+307,B:B)

E3, copied down:

=IF(ROW()-ROW(E$3)+1<=$E$1,INDEX(A:A,MATCH(ROW()-ROW(E$3)+1,B:B)),"")

F3, copied down:

=IF(E3<>"",COUNTIF(A:A,E3),"")
 
Upvote 0

Forum statistics

Threads
1,216,071
Messages
6,128,622
Members
449,460
Latest member
jgharbawi

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