Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Sumproduct
When I enter the formula below, the result I get is 0, when it should
be 490 If Cells N5:N9,N22:N26,N39:N43 = A11 THEN SUM D5:D9,D22:D26,D39:D43 =SUMPRODUCT(--(Sheet1!N5:N9=A11)--(Sheet1!D5:D9),--(Sheet1!N22:N26=A11),--(Sheet1!D22:D26),--(Sheet1!N39:N43=A11),--(Sheet1!D39:D43)) Any ideas? Pete |
#2
|
|||
|
|||
=SUMPRODUCT(--(Sheet1!N5:N9=A11),Sheet1!D5:D9)+SUMPRODUCT(--(Sheet1!N22:N26=
A11),Sheet1!D22:D26)+SUMPRODUCT(--(Sheet1!N39:N43=A11),Sheet1!D39:D43) -- HTH RP (remove nothere from the email address if mailing direct) "Pete" wrote in message oups.com... When I enter the formula below, the result I get is 0, when it should be 490 If Cells N5:N9,N22:N26,N39:N43 = A11 THEN SUM D5:D9,D22:D26,D39:D43 =SUMPRODUCT(--(Sheet1!N5:N9=A11)--(Sheet1!D5:D9),--(Sheet1!N22:N26=A11),--(S heet1!D22:D26),--(Sheet1!N39:N43=A11),--(Sheet1!D39:D43)) Any ideas? Pete |
#3
|
|||
|
|||
And also, do you want to sum D22:D26, as you state, or N22:N26, as per your
formula "Pete" wrote: When I enter the formula below, the result I get is 0, when it should be 490 If Cells N5:N9,N22:N26,N39:N43 = A11 THEN SUM D5:D9,D22:D26,D39:D43 =SUMPRODUCT(--(Sheet1!N5:N9=A11)--(Sheet1!D5:D9),--(Sheet1!N22:N26=A11),--(Sheet1!D22:D26),--(Sheet1!N39:N43=A11),--(Sheet1!D39:D43)) Any ideas? Pete |
#4
|
|||
|
|||
try
=SUMPRODUCT(--(Sheet1!N5:N9=A11)*(Sheet1!D5:D9),--(Sheet1!N22:N26=A11)*(Sheet1!D22:D26),--(Sheet1!N39:N43=A11)*(Sheet1!D39:D43)) I am surprised you got zero for an answer, I am not surprised you did not get the right answer. in sumproduct each array separated by a "," is multiplied together as such in your equation the first number would have been [(1 or 0)+D5]*(1or0)*D22*(1 or 0)*D39 other combos similar. most patterns would have given some value other than zero for a total of all the combinations. Please check if your D column actually has numbers and not numbers in text format if you just do = dum(D5:D9) what do you get? "Pete" wrote: When I enter the formula below, the result I get is 0, when it should be 490 If Cells N5:N9,N22:N26,N39:N43 = A11 THEN SUM D5:D9,D22:D26,D39:D43 =SUMPRODUCT(--(Sheet1!N5:N9=A11)--(Sheet1!D5:D9),--(Sheet1!N22:N26=A11),--(Sheet1!D22:D26),--(Sheet1!N39:N43=A11),--(Sheet1!D39:D43)) Any ideas? Pete |
#6
|
|||
|
|||
Pete wrote:
When I enter the formula below, the result I get is 0, when it should be 490 If Cells N5:N9,N22:N26,N39:N43 = A11 THEN SUM D5:D9,D22:D26,D39:D43 =SUMPRODUCT(--(Sheet1!N5:N9=A11)--(Sheet1!D5:D9),--(Sheet1!N22:N26=A11),--(Sheet1!D22:D26),--(Sheet1!N39:N43=A11),--(Sheet1!D39:D43)) Any ideas? Pete =SUM(SUMIF(Sheet1!$N$5:$N$9,A11,Sheet1!$D$5:$D$9), SUMIF(Sheet1!$N$22:$N$26,A11,Sheet1!$D$22:$D$26), SUMIF(Sheet1!$N$39:$N$43,A11,Sheet1!$D$39:$D$43)) |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Sumproduct | Excel Worksheet Functions | |||
sumproduct causing memory errors? | Excel Worksheet Functions | |||
Can I reference =, <, or > sign in SUMPRODUCT | Excel Discussion (Misc queries) | |||
Sumproduct function not working | Excel Worksheet Functions | |||
adding two sumproduct formulas together | Excel Worksheet Functions |