Using subtotal & filters, but how to subtract a certain row within the filter?

vgupta23

New Member
Joined
Sep 4, 2013
Messages
1
Hey everyone,

Hope you can help. Let us say this is my data:

[TABLE="width: 300"]
<TBODY>[TR]
[TD]MONDAY </SPAN>[/TD]
[TD]MORNING</SPAN>[/TD]
[TD]100</SPAN>[/TD]
[/TR]
[TR]
[TD]MONDAY </SPAN>[/TD]
[TD]DAY</SPAN>[/TD]
[TD]200</SPAN>[/TD]
[/TR]
[TR]
[TD]MONDAY </SPAN>[/TD]
[TD]NIGHT</SPAN>[/TD]
[TD]400</SPAN>[/TD]
[/TR]
[TR]
[TD]TUESDAY</SPAN>[/TD]
[TD]MORNING</SPAN>[/TD]
[TD]300</SPAN>[/TD]
[/TR]
[TR]
[TD]TUESDAY</SPAN>[/TD]
[TD]DAY</SPAN>[/TD]
[TD]300</SPAN>[/TD]
[/TR]
[TR]
[TD]TUESDAY</SPAN>[/TD]
[TD]NIGHT</SPAN>[/TD]
[TD]200</SPAN>[/TD]
[/TR]
[TR]
[TD]WEDNESDAY</SPAN>[/TD]
[TD]MORNING</SPAN>[/TD]
[TD]100</SPAN>[/TD]
[/TR]
[TR]
[TD]WEDNESDAY</SPAN>[/TD]
[TD]DAY</SPAN>[/TD]
[TD]100</SPAN>[/TD]
[/TR]
[TR]
[TD]WEDNESDAY</SPAN>[/TD]
[TD]NIGHT</SPAN>[/TD]
[TD]400</SPAN>[/TD]
[/TR]
</TBODY><COLGROUP><COL><COL><COL></COLGROUP>[/TABLE]

So if I use the subtotal formula, and filter for only monday, it will sum my total revenue for morning, day, and night. When i use subtotal and filter for Monday, it will return $700. if i use =SUBTOTAL(9, C1:C9) - SUMIF(B1:B9, "NIGHT", C1:C9), then answer will be $700-($1000) = -$300.

How do i filter for monday, but only subtotal for revenue in the morning and day, but get rid of night? total should be $600 .. ?

Hopefully some can answer ... thanks


Vee
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.

Forum statistics

Threads
1,223,903
Messages
6,175,279
Members
452,630
Latest member
OdubiYouth

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