Change SUMIF and CHANGIF formulas so that filtered data only gets calculated.

bored622

New Member
Joined
Mar 2, 2022
Messages
43
Office Version
  1. 2016
Platform
  1. Windows
Hello, I currently have these formulas that calculate data from another tab's table, but if I filter data out of the table, my formulas still calculate the filtered out data. I'm pretty new to excel, but I've read a few forums on using SUMPRODUCT to get the results I want but not sure how to do it. Below I have posted a few formulas. If anyone can help, it would be greatly appreciated.

=COUNTIF(USSW1!$V$7:$V$25000,465)

=SUMIF(USSW1!$V$7:$V$25000,"465",USSW1!$O$7:$O$25000)-SUMIFS(USSW1!$O$7:$O$25000,USSW1!$M$7:$M$25000,"FP",USSW1!$V$7:$V$25000,"465")

=COUNTIFS(USSW1!$V$7:$V$25000,"465",USSW1!$M$7:$M$25000,"FP")

=SUMIF(USSW1!$V$7:$V$25000,"465",USSW1!$O$7:$O$25000)-SUMIFS(USSW1!$O$7:$O$25000,USSW1!$M$7:$M$25000,"CA",USSW1!$V$7:$V$25000,"465")-SUMIFS(USSW1!$O$7:$O$25000,USSW1!$M$7:$M$25000,"CF",USSW1!$V$7:$V$25000,"465")

=SUMIF(USSW1!$V$7:$V$25000,"465",USSW1!$O$7:$O$25000)
 
You will need to change the SUMIF to SUMIFS as SUMIF does not allow more than one criteria.
I changed my formula and got it to work.
I went from:
=SUMIF(USSW1!$V$7:$V$25000,"465",USSW1!$O$7:$O$25000)-SUMIFS(USSW1!$O$7:$O$25000,USSW1!$M$7:$M$25000,"FP",USSW1!$V$7:$V$25000,"465")-SUMIFS(USSW1!$O$7:$O$25000,USSW1!$M$7:$M$25000,"BK",USSW1!$V$7:$V$25000,"465")
to
=SUM(SUMIFS(USSW1!O7:O50000,USSW1!M7:M50000,{"CA","CF"},USSW1!V7:V50000,{"465"},USSW1!W7:W50000,1))
and now it filters out the data I wanted. Thank you
 
Upvote 0

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
Glad you sorted it & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,223,896
Messages
6,175,260
Members
452,627
Latest member
KitkatToby

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