sumif

mjoyce1994

New Member
Joined
Sep 25, 2019
Messages
6
i'm trying to do a sumif

i tried attaching a photo but not sure it worked and don't want to attach my excel at the moment

sumif(I:I,"1",(e119+J119))


The part in red is where I think i'm messing up. What I'm trying to say here is sumif the result in column I is "1" then sum these two cells.
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.
Hi & welcome to MrExcel.
What exactly do you mean by column I is "1"?
 
Upvote 0
Are you looking at the whole column of I, and then just summing columns E and J in row 119, or do you mean to check each row, and if column I in that row is 1, then add columns E and J?
If so, then you would use a formula like:
Code:
=IF(I119=1,E119+J119,0)
(is I is entered as a number)
or
Code:
=IF(I119="1",E119+J119,0)
if column I is entered as text.
 
Upvote 0
Are you looking at the whole column of I, and then just summing columns E and J in row 119, or do you mean to check each row, and if column I in that row is 1, then add columns E and J?
If so, then you would use a formula like:
Code:
=IF(I119=1,E119+J119,0)
(is I is entered as a number)
or
Code:
=IF(I119="1",E119+J119,0)
if column I is entered as text.



The second one worked exactly as i wanted it to!!
 
Upvote 0
Another question... the second if statement worked, btw! Lets say I wanted to not see #N/A's and wanted to see "-" instead, how would I add that to the formula?
 
Upvote 0
In what situation are you getting #N/A's?
There must be an error or some unexpected value in columns I, E, or J.
Which one is it, and what is in that cell?
 
Upvote 0
It's due to a vlookup from another column.


For learning purposes, just wondering how to make it "-" instead of "n/a"
 
Upvote 0
It's due to a vlookup from another column.
But which column has this VLOOKUP? I, E or J?
If you would like me to amend the formula, I need to know which part (column reference) needs to be amended!
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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