Trying to sum data that fits certain criteria

jc77

New Member
Joined
Feb 17, 2012
Messages
6
I can't seem to figure this out.

I'm trying to sum data that fits w/in two dates I've specified. Normally, this would be a simple sumif formula. But the data I'm actually summing has text string and so Excel doesn't see the numerical values to be able to add them.

Here's what my data table looks like.

Task / Duration Hrs / Start Date
A / 3 hrs / 2/1/12 08:00
B / 6 hrs / 2/6/12 16:00

I want to sum the total duration hrs for all tasks that start sometime between "Feb 1 0:00" and "Feb 29 23:59" so I want Excel to return the value "9" in this example. I know how to use LEFT LEN to return duration hours values if I was evaluating each cell individually but not sure how to combine if w/ the sumif formula if I want to analyze an entire worksheet of data.

Should I be using another formula? Thank you very much for your help.
 
Thank you very much, T. Valko. That works great!

Is this:
--LEFT(B2:B9,FIND(" ",B2:B9)

the portion of the formula that returns the numerical value?

What does FIND " " mean?
 
Upvote 0
Thank you very much, T. Valko. That works great!
You're welcome!

Is this:
--LEFT(B2:B9,FIND(" ",B2:B9)

the portion of the formula that returns the numerical value?

What does FIND " " mean?

FIND(" ", means to find the position number of the space character in the Duration Hrs range. We want to extract the numbers to the left of the space character.

So, this part of the formula:

--LEFT(B2:B9,FIND(" ",B2:B9)

Evaluates this:

Book1
B
1Duration Hrs
23 hrs
36 hrs
410 hrs
52.5 hrs
62 hrs
72 hrs
87 hrs
91 hr
Sheet1

Like this:

Book1
B
1Duration Hrs
23
36
410
52.5
62
72
87
91
Sheet1

So that these numbers can then be summed when they fall within the date range.
 
Upvote 0
Wow. Good to know. I will remember that for the future.

Thank you very much, once again. You are awesome!!!
 
Upvote 0

Forum statistics

Threads
1,226,771
Messages
6,192,924
Members
453,767
Latest member
922aloose

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