Sumif formula error

fekka

New Member
Joined
Apr 19, 2010
Messages
22
Hi all,
I am trying to get a count of all people who match two variables.
First is their work type being level 1, 2 or 3) and finally whether they are full time or part time.

This is the current formula I have and it was working, but now its not.

=SUM(IF($F$9:$F$1946=$U2,IF($G$9:$G$1946=W$1,1,0),0))

Column F is made up of Type (1,2 or 3)
Column G is made up of hours (FT or PT)
W1 = FT, UT = 1 (for this example)

Currently the error I am getting is #value

Thanks for having a look
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
Hi all,
I am trying to get a count of all people who match two variables.
First is their work type being level 1, 2 or 3) and finally whether they are full time or part time.

This is the current formula I have and it was working, but now its not.

=SUM(IF($F$9:$F$1946=$U2,IF($G$9:$G$1946=W$1,1,0),0))

Column F is made up of Type (1,2 or 3)
Column G is made up of hours (FT or PT)
W1 = FT, UT = 1 (for this example)

Currently the error I am getting is #value

Thanks for having a look
Your formula is syntactically correct but did you enter it as an array formula with the key combination of CTRL, SHIFT, ENTER?

You said the formula used to work. Did you maybe edit it and forget to re-enter as an array?

What version of Excel are you using?

Are there any #VALUE! errors in any of the ranges?
 
Upvote 0
Try substituting sum with count. If your using excel 2007 or later theres a formula called countifs which allows you to make a count with more than 1 criteria which should suit you
 
Upvote 0
I am using Excel 2003, and I didn't enter it as an array formula.
The formula works in this format

{=SUM(IF($F$9:$F$1936=$U2,IF($G$9:$G$1936=W$1,1,0),0))}

but as soon as go into the formula and enter out, it fails and I can't get the original data back.

Tried COUNT (as per scottylad2) however that just returned zeros

Thanks
 
Upvote 0
I am using Excel 2003, and I didn't enter it as an array formula.
The formula works in this format

{=SUM(IF($F$9:$F$1936=$U2,IF($G$9:$G$1936=W$1,1,0),0))}

but as soon as go into the formula and enter out, it fails and I can't get the original data back.

Tried COUNT (as per scottylad2) however that just returned zeros

Thanks
I'm not sure what that highlighted portion means.

Try this normally entered formula:

=SUMPRODUCT(--($F$9:$F$1936=$U2),--($G$9:$G$1936=W$1))
 
Upvote 0
Excel Workbook
FGHI
41FT1FT
52FT
63FT3
72FT3
82PT3
91PT
101PT
113FT
123PT
133FT
141FT
153PT
163PT
172PT
181FT
191PT
Sheet1


As Bif said, the Sum(If and the Count(IF are both array formulas, which means each time you go into and edit the formula you will need to re enter the formula cell with ctrl + shift + enter not just enter. The sumproduct option can handle arrays though and only needs entered in the usual way, ie press enter
 
Upvote 0

Forum statistics

Threads
1,224,594
Messages
6,179,795
Members
452,943
Latest member
Newbie4296

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