formula of sum after filter on specific range

arikh

New Member
Joined
Jan 6, 2021
Messages
4
Office Version
  1. 2019
  2. 2016
  3. 2013
Platform
  1. Windows
I have a data of days with details for each students. (S,F,L,V)
i would like to count each one for all the table.
more than i would like to sum the data after filter on specific range (such only first class on 22 on month )
Attached a file for example - will really glade to understand how to do it
Thank a lot

1609974784583.png
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK
Hi

I set up your data like the following.

1609982863378.png


Enter the following formula in B10 and copy it down.

=COUNTIFS($C$3:$G$6,A10)

And then enter the following formula in B20 and copy it down.

= SUMPRODUCT(--((INDEX($C$3:$G$6,,MATCH($B$17,$C$2:$G$2,0))=A20))*(--($A$3:$A$6=$B$19))*(--($B$3:$B$6=$B$18)))



Kind regards

Saba
 

Attachments

  • 1609982837966.png
    1609982837966.png
    9 KB · Views: 2
Upvote 0
Solution
Hi

I set up your data like the following.

View attachment 29252

Enter the following formula in B10 and copy it down.

=COUNTIFS($C$3:$G$6,A10)

And then enter the following formula in B20 and copy it down.

= SUMPRODUCT(--((INDEX($C$3:$G$6,,MATCH($B$17,$C$2:$G$2,0))=A20))*(--($A$3:$A$6=$B$19))*(--($B$3:$B$6=$B$18)))



Kind regards

Saba
Really thanks ...
But in case i want not to filter name or class (means i would like it to be only options) , what should i do ?
once i remove it , the results are 0 because it search null , i tried if but still return null
Thankss
 
Upvote 0
Try this:
New Microsoft Excel Worksheet.xlsx
ABCDEFG
1
2NameClass12345
3aaaaSSsfv
5cccbflsvs
6dddbvffsf
7
8CountAllCountVisible
9s76
10l41
11f55
12v43
Sheet2
Cell Formulas
RangeFormula
B9:B12B9=SUMPRODUCT(--($C$3:$G$6=$A9))
C9:C12C9=SUMPRODUCT(($C$3:$G$6=$A9)*(SUBTOTAL(103,OFFSET($C$3,ROW($C$3:$C$6)-MIN(ROW($C$3:$C$6)),0))))
 
Upvote 0
Nice that visible option ...
I tried to use only one filter on the class and it failed , why ? (from the example above)
=SUMPRODUCT(--((INDEX($C$3:$G$6,,MATCH($B$18,$B$3:$B$6,0))=A20)))
(Once the data is not unique it not sum all of them ... )
 
Upvote 0
@arikh Are you test my Method? it really working well.
Yes it working well , but i have 2 sheets .
The first one that include all data
The second one is summarize all .
In the second one i just filter it by my self by 3 options :
1 - sum all data by filtered date + class .
2 - sum data by filtered date
3 - filter data by class ... in that one i have a problem - it's not working with this formula so will glade to undertand why ?
=SUMPRODUCT(--((INDEX($C$3:$G$6,,MATCH($B$18,$B$3:$B$6,0))=A20))) or maybe u have something more clever :)
Thanks a lot
 
Upvote 0

Forum statistics

Threads
1,215,046
Messages
6,122,854
Members
449,096
Latest member
Erald

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