Joining a sumproduct function

sbrowner

New Member
Joined
Nov 6, 2007
Messages
11
My formulas work as a stand alone but I need to have a sumproduct formula to pickup Branch 1 and Branch 2 and total them in the same column.

Current formula in two separate columns:

=SUMPRODUCT((BRANCH07="01")*(DEPT07="20")*(CATEGORY_DETAIL07=$A10)*(JUN_07_YTD))*-1

=SUMPRODUCT((BRANCH07="02")*(DEPT07="20")*(CATEGORY_DETAIL07=$A10)*(JUN_07_YTD))*-1

I thought it would be so simple to join them but I clearly am missing something because I keep getting errors.

Thanks
 

Excel Facts

Square and cube roots
The =SQRT(25) is a square root. For a cube root, use =125^(1/3). For a fourth root, use =625^(1/4).
This should really be in the Excel questions forum, but:
=-SUMPRODUCT(--((BRANCH07="01")+(BRANCH07="20")>0),--(DEPT07="20"),--(CATEGORY_DETAIL07=$A10),JUN_07_YTD)
 
Upvote 0
Hi

A similar one:

=-SUMPRODUCT((BRANCH07="01")+(BRANCH07="20"),--(DEPT07="20"),--(CATEGORY_DETAIL07=$A10),JUN_07_YTD)
 
Upvote 0
Or

=-SUMPRODUCT((BRANCH07={"01","20"})*(DEPT07="20")*(CATEGORY_DETAIL07=$A10),JUN_07_YTD)

EDIT: Looking at that, I expect the two other alternatives are faster.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,224,607
Messages
6,179,871
Members
452,949
Latest member
Dupuhini

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