AliAlhashim
New Member
- Joined
- May 13, 2018
- Messages
- 3
Dears,
I have the following table:
[TABLE="width: 377"]
<tbody>[TR]
[TD]Name/Month[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]5[/TD]
[TD="align: right"]4[/TD]
[/TR]
[TR]
[TD]Nissan[/TD]
[TD="align: right"]100[/TD]
[TD="align: right"]140[/TD]
[TD="align: right"]120[/TD]
[TD="align: right"]30[/TD]
[/TR]
[TR]
[TD]Honda[/TD]
[TD="align: right"]45[/TD]
[TD="align: right"]456[/TD]
[TD="align: right"]4[/TD]
[TD="align: right"]841[/TD]
[/TR]
[TR]
[TD]Toyota[/TD]
[TD="align: right"]4[/TD]
[TD="align: right"]7[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]26[/TD]
[/TR]
</tbody><colgroup><col><col span="4"></colgroup>[/TABLE]
What I'm trying to do is to sum numbers in this table based on some criteria for rows and columns.
For example, I want to sum Nissan for the months of 1 & 5.
What I have reached so far is this formula: =SUMPRODUCT((A2:A4="Nissan")*(B1:E1=1)*B2:E4)
However, I'm unable to add multiple months to this formula.
Any help?
I have the following table:
[TABLE="width: 377"]
<tbody>[TR]
[TD]Name/Month[/TD]
[TD="align: right"]1[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]5[/TD]
[TD="align: right"]4[/TD]
[/TR]
[TR]
[TD]Nissan[/TD]
[TD="align: right"]100[/TD]
[TD="align: right"]140[/TD]
[TD="align: right"]120[/TD]
[TD="align: right"]30[/TD]
[/TR]
[TR]
[TD]Honda[/TD]
[TD="align: right"]45[/TD]
[TD="align: right"]456[/TD]
[TD="align: right"]4[/TD]
[TD="align: right"]841[/TD]
[/TR]
[TR]
[TD]Toyota[/TD]
[TD="align: right"]4[/TD]
[TD="align: right"]7[/TD]
[TD="align: right"]46[/TD]
[TD="align: right"]26[/TD]
[/TR]
</tbody><colgroup><col><col span="4"></colgroup>[/TABLE]
What I'm trying to do is to sum numbers in this table based on some criteria for rows and columns.
For example, I want to sum Nissan for the months of 1 & 5.
What I have reached so far is this formula: =SUMPRODUCT((A2:A4="Nissan")*(B1:E1=1)*B2:E4)
However, I'm unable to add multiple months to this formula.
Any help?