Sum if

nada

Board Regular
Joined
Jul 4, 2006
Messages
193
Hi! I want to check column B. If there are observation in B that are smaller than A2 then I want to sum them and place them in C. This formula works for me:

=SUM.IF($B$2:$B$265;"<2";$C$2:$C$265)

However then I cannot have a variable instead of 2. I want to write:

=SUM.IF($B$2:$B$265;<A2;$C$2:$C$265)

but that does not work. Please help! Thanks alot!
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
nada

I'm afraid your 2nd formula didn't show correctly in the post so this is a guess.
Code:
=SUM.IF($B$2:$B$265;"<" & A2;$C$2:$C$265)
 
Upvote 0
yes! that is what I want but i cannot get the syntax to work. I try writing:

=SUMMA.OM($B$2:$B$265;<A2;$C$2:$C$265)

but that gives me error. Please help me!!
 
Upvote 0
missing code

=SUMMA.OM($B$2:$B$265;<A2;$C$2:$C$265)

is the code that i am trying to write.
 
Upvote 0
hi Norie! no i did not get that to work. But that is what I want to do. please please help me!
 
Upvote 0
Try...

=SUMMA.OM($B$2:$B$265;"<"&A2;$C$2:$C$265)

Hope this helps!
 
Upvote 0

Forum statistics

Threads
1,214,987
Messages
6,122,614
Members
449,090
Latest member
vivek chauhan

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