SUMIF

twoboys

New Member
Joined
Jan 22, 2005
Messages
7
I can't figure out why this formula won't work. The range and criteria are dates (ie: 01/15/05) and the Sum_Range refers to hours worked.

=SUMIF('January 05'!A6:A67,'Carol''s Payroll Sheet'!A1:A14,'January 05'!D6:D67)

I keep getting a 0 for my answer or it only calculates some of the hours worked.

As you can see, I am using 2 different worksheets...though I don't think that's the problem!?!?!
 

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)

jindon

MrExcel MVP
Joined
Aug 21, 2004
Messages
16,995
Hi,

The second argument for the SUMIF function should be single cell reference.

if you need to sum under multiple conditions, array formula or sumproduct function will solve the problem.

hope this helps

jindon
 

ken2step

Well-known Member
Joined
Jan 9, 2003
Messages
642
Your 2nd argument the criteria is more then one cell A1:A14....that is your problem. It only looks for the first item probably in A1 not the rest.
 

Aladin Akyurek

MrExcel MVP
Joined
Feb 14, 2002
Messages
85,210
twoboys said:
I can't figure out why this formula won't work. The range and criteria are dates (ie: 01/15/05) and the Sum_Range refers to hours worked.

=SUMIF('January 05'!A6:A67,'Carol''s Payroll Sheet'!A1:A14,'January 05'!D6:D67)

I keep getting a 0 for my answer or it only calculates some of the hours worked.

As you can see, I am using 2 different worksheets...though I don't think that's the problem!?!?!

Assuming that you want a sum for certain dates enumerated in 'Carol''s Payroll Sheet'!A1:A14...

One of:

=SUMPRODUCT(SUMIF('January 05'!A6:A67,'Carol''s Payroll Sheet'!A1:A14,'January 05'!D6:D67))

=SUMPRODUCT(--ISNUMBER(MATCH('January 05'!A6:A67,'Carol''s Payroll Sheet'!A1:A14,0)),'January 05'!D6:D67)
 

twoboys

New Member
Joined
Jan 22, 2005
Messages
7
BRILLIANT!!!

Thank you!
 

ken2step

Well-known Member
Joined
Jan 9, 2003
Messages
642
I'll 2nd that one twoboys!!! I tried for about an hour to get you something to no avail......Aladin teachs me something everytime I visit Mr. Excel! Thanks again Aladin!!
 

ken2step

Well-known Member
Joined
Jan 9, 2003
Messages
642
No problem my friend! I was hoping Aladin come by.....I knew he would have an answer for you. Trust me I logged that one in the archives for future use myself!
 

Forum statistics

Threads
1,181,251
Messages
5,928,937
Members
436,635
Latest member
mercessb

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
Top