Running total for 2 columns IF column 3.......

P

paulab

Can anyone help, I am trying to keep a running total of impressions based on
daily entries throughout the month:
If column G = "letter" than column C (sets) * column E (pages)
If column G = "tabloid" than column C (sets) * column E (pages)*2

Thank you in advance,
paulab
 
J

Jacob Skaria

Try the below

=SUMPRODUCT((G1:G10="letter")*C1:C10*E1:E10)

=SUMPRODUCT((G1:G10="tabloid")*C1:C10*E1:E10*2)

If this post helps click Yes
 
L

Luke M

What happens if G does not equal either of those choices? In this formula, it
causes the result to be 0.

=C2*E2*IF(G2="letter",1,IF(G2="tabloid",2,0)
 
E

Eduardo

Hi,
try

=IF(SUMPRODUCT((A1:A4="letter")*(B1:B4*E1:E4))>0,SUMPRODUCT((A1:A4="letter")*(B1:B4*E1:E4)),IF(SUMPRODUCT((A1:A4="tabloid")*(B1:B4*E1:E4*2))>0,SUMPRODUCT((A1:A4="tabloid")*(B1:B4*E1:E4*2))))
 
E

Eduardo

hI,
This formula will work better specially if you have both words in the column

=SUMPRODUCT((A1:A5="tabloid")*(B1:B5*E1:E5*2))+SUMPRODUCT((A1:A5="letter")*(B1:B5*E1:E5))
 
P

paulab

Perfect!!
Thank you

Eduardo said:
hI,
This formula will work better specially if you have both words in the column

=SUMPRODUCT((A1:A5="tabloid")*(B1:B5*E1:E5*2))+SUMPRODUCT((A1:A5="letter")*(B1:B5*E1:E5))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top