ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Sum value Upper 0 (https://www.excelbanter.com/excel-discussion-misc-queries/45150-sum-value-upper-0-a.html)

ldiaz

Sum value Upper 0
 

I want to sum datas of a column with these Datas.

Usage Total Price
33.5 $65.5
-32.5 $-50.5
-1.5 $-5
1.5 $5

But I want to Sum only values upper 0. it should be: Usage Total: 35.5 &
$70.5

also I want the viceversa.



please help

ldiaz



RagDyer

If you want separate totals for each column:

=SUMIF(A2:A5,"0")
=SUMIF(B2:B5,"0")

=SUMIF(A2:A5,"<0")
=SUMIF(B2:B5,"<0")

--
HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================


"ldiaz" wrote in message
...

I want to sum datas of a column with these Datas.

Usage Total Price
33.5 $65.5
-32.5 $-50.5
-1.5 $-5
1.5 $5

But I want to Sum only values upper 0. it should be: Usage Total: 35.5 &
$70.5

also I want the viceversa.



please help

ldiaz




Don Guillett

a simple sumif should do it
=SUMIF(H2:H22,"0")
or
=SUMPRODUCT((H2:H220)*H2:H22)

--
Don Guillett
SalesAid Software

"ldiaz" wrote in message
...

I want to sum datas of a column with these Datas.

Usage Total Price
33.5 $65.5
-32.5 $-50.5
-1.5 $-5
1.5 $5

But I want to Sum only values upper 0. it should be: Usage Total: 35.5 &
$70.5

also I want the viceversa.



please help

ldiaz





Dave Peterson

Take a look at =sumif() in excel's help:

=sumif(a2:a99,"0")
and
=sumif(a2:a99,"<0")

You could even put a value in another cell:

=sumif(a2:a99,"<"&b1)
to add up all the values less than the value in B1

ldiaz wrote:

I want to sum datas of a column with these Datas.

Usage Total Price
33.5 $65.5
-32.5 $-50.5
-1.5 $-5
1.5 $5

But I want to Sum only values upper 0. it should be: Usage Total: 35.5 &
$70.5

also I want the viceversa.

please help

ldiaz


--

Dave Peterson

Roger Govier

One way
=SUMPRODUCT(--(A1:A40),A1:A4)
for total positive values - answer is 35 not 35.5

=SUMPRODUCT(--(A1:A4<0),A1:A4)
for total negative values - answer -34.0

Change ranges for price and alter range size to suit.

Regards

Roger Govier


ldiaz wrote:
I want to sum datas of a column with these Datas.

Usage Total Price
33.5 $65.5
-32.5 $-50.5
-1.5 $-5
1.5 $5

But I want to Sum only values upper 0. it should be: Usage Total: 35.5 &
$70.5

also I want the viceversa.



please help

ldiaz



ldiaz

To all answered my question I want to thanks and say: Thank you so much...

Ldiaz


"Dave Peterson" wrote:

Take a look at =sumif() in excel's help:

=sumif(a2:a99,"0")
and
=sumif(a2:a99,"<0")

You could even put a value in another cell:

=sumif(a2:a99,"<"&b1)
to add up all the values less than the value in B1

ldiaz wrote:

I want to sum datas of a column with these Datas.

Usage Total Price
33.5 $65.5
-32.5 $-50.5
-1.5 $-5
1.5 $5

But I want to Sum only values upper 0. it should be: Usage Total: 35.5 &
$70.5

also I want the viceversa.

please help

ldiaz


--

Dave Peterson


B. R.Ramachandran

Hi,

Use the formulas,

=SUMIF(A2:A100,"0") for summing positive quantities, and
=SUMIF(A2:A100,"<0") for summing negative quantities,

where A2:A100 is the range of cells considered. Modify the range
appropriately.

Regards,
B. R. Ramachandran

"ldiaz" wrote:


I want to sum datas of a column with these Datas.

Usage Total Price
33.5 $65.5
-32.5 $-50.5
-1.5 $-5
1.5 $5

But I want to Sum only values upper 0. it should be: Usage Total: 35.5 &
$70.5

also I want the viceversa.



please help

ldiaz




All times are GMT +1. The time now is 06:12 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com