Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
APYDS
 
Posts: n/a
Default how do i count how many people are working between two times in e

I am trying to prepare a rota for my carers in a nursing home on Excel. We
have carers working 24 hours a day in the nursing home but the number of
carers vary according to the number of residents that we are caring for and
the time of day.

I would like to count on my rota the number of carers working between two
times. I have set up my worksheet so that, for instance, the start time of
each carers shift is displayed between cells B6:B26 and the end time between
cells c6:c26 for each respective carer.

I want the spread sheet to count the number of carers working between the
start time entered in cells b28 and the end time entered in cell c28. Note
that night carers may work, for instance, between 8 pm on one day and 8 am on
the following day.

I have tried entering the formula
=COUNTIF(B6:B26,"=b28")-COUNTIF(C6:C26,"<=c28") but it does not seem to work
for any time of day. Anyone have the answer to the formula I would use?

  #2   Report Post  
Bob Phillips
 
Posts: n/a
Default

Give this a try

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"APYDS" wrote in message
...
I am trying to prepare a rota for my carers in a nursing home on Excel.

We
have carers working 24 hours a day in the nursing home but the number of
carers vary according to the number of residents that we are caring for

and
the time of day.

I would like to count on my rota the number of carers working between two
times. I have set up my worksheet so that, for instance, the start time

of
each carers shift is displayed between cells B6:B26 and the end time

between
cells c6:c26 for each respective carer.

I want the spread sheet to count the number of carers working between the
start time entered in cells b28 and the end time entered in cell c28.

Note
that night carers may work, for instance, between 8 pm on one day and 8 am

on
the following day.

I have tried entering the formula
=COUNTIF(B6:B26,"=b28")-COUNTIF(C6:C26,"<=c28") but it does not seem to

work
for any time of day. Anyone have the answer to the formula I would use?



  #3   Report Post  
APYDS
 
Posts: n/a
Default

Thanks for the help. Firstly when I first looked at your reply the formula
was displayed as ("formula 1"):

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

Now trying to reply to you, I noted it is displayed as ("formula 2"):

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

In Formula one excel displayed and error and the "lt" was highlighted.

Formula two was accepted without an error but when I tested it with some
times in cells b6 & c6 it still showed 00:00.

Thanks anyway


"Bob Phillips" wrote:

Give this a try

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"APYDS" wrote in message
...
I am trying to prepare a rota for my carers in a nursing home on Excel.

We
have carers working 24 hours a day in the nursing home but the number of
carers vary according to the number of residents that we are caring for

and
the time of day.

I would like to count on my rota the number of carers working between two
times. I have set up my worksheet so that, for instance, the start time

of
each carers shift is displayed between cells B6:B26 and the end time

between
cells c6:c26 for each respective carer.

I want the spread sheet to count the number of carers working between the
start time entered in cells b28 and the end time entered in cell c28.

Note
that night carers may work, for instance, between 8 pm on one day and 8 am

on
the following day.

I have tried entering the formula
=COUNTIF(B6:B26,"=b28")-COUNTIF(C6:C26,"<=c28") but it does not seem to

work
for any time of day. Anyone have the answer to the formula I would use?




  #4   Report Post  
RagDyeR
 
Posts: n/a
Default

First of all, make sure that the data in Columns B & C, as well as B28 & C28
are *true* XL recognized times.

Secondly, the formula should be entered in a cell formatted as "General" or
"Number"!

The return you mentioned of
00:00
Is proof that the formula cell is *NOT* formatted correctly.
--

HTH,

RD
================================================== ===
Please keep all correspondence within the Group, so all may benefit!
================================================== ===

"APYDS" wrote in message
...
Thanks for the help. Firstly when I first looked at your reply the formula
was displayed as ("formula 1"):

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

Now trying to reply to you, I noted it is displayed as ("formula 2"):

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

In Formula one excel displayed and error and the "lt" was highlighted.

Formula two was accepted without an error but when I tested it with some
times in cells b6 & c6 it still showed 00:00.

Thanks anyway


"Bob Phillips" wrote:

Give this a try

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"APYDS" wrote in message
...
I am trying to prepare a rota for my carers in a nursing home on Excel.

We
have carers working 24 hours a day in the nursing home but the number of
carers vary according to the number of residents that we are caring for

and
the time of day.

I would like to count on my rota the number of carers working between

two
times. I have set up my worksheet so that, for instance, the start time

of
each carers shift is displayed between cells B6:B26 and the end time

between
cells c6:c26 for each respective carer.

I want the spread sheet to count the number of carers working between

the
start time entered in cells b28 and the end time entered in cell c28.

Note
that night carers may work, for instance, between 8 pm on one day and 8

am
on
the following day.

I have tried entering the formula
=COUNTIF(B6:B26,"=b28")-COUNTIF(C6:C26,"<=c28") but it does not seem to

work
for any time of day. Anyone have the answer to the formula I would use?






  #5   Report Post  
APYDS
 
Posts: n/a
Default

Thanks, that solved one problem and now at least it is counting. The problem
becomes if a shift starts at 20:00 on one day and ends at 8:00 on the
following day. The coloumns in B28 and C28 will only display 20:00 and 8:00.
If I want to know the number of people working between 8:00 and 14:00 it
will assume that the night workers are working during the day. Is there any
way to get round this without having to put dates into the rota?


"RagDyeR" wrote:

First of all, make sure that the data in Columns B & C, as well as B28 & C28
are *true* XL recognized times.

Secondly, the formula should be entered in a cell formatted as "General" or
"Number"!

The return you mentioned of
00:00
Is proof that the formula cell is *NOT* formatted correctly.
--

HTH,

RD
================================================== ===
Please keep all correspondence within the Group, so all may benefit!
================================================== ===

"APYDS" wrote in message
...
Thanks for the help. Firstly when I first looked at your reply the formula
was displayed as ("formula 1"):

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

Now trying to reply to you, I noted it is displayed as ("formula 2"):

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

In Formula one excel displayed and error and the "lt" was highlighted.

Formula two was accepted without an error but when I tested it with some
times in cells b6 & c6 it still showed 00:00.

Thanks anyway


"Bob Phillips" wrote:

Give this a try

=SUMPRODUCT(--(B6:B27<=B28),--(C6:C27=C28))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"APYDS" wrote in message
...
I am trying to prepare a rota for my carers in a nursing home on Excel.

We
have carers working 24 hours a day in the nursing home but the number of
carers vary according to the number of residents that we are caring for

and
the time of day.

I would like to count on my rota the number of carers working between

two
times. I have set up my worksheet so that, for instance, the start time

of
each carers shift is displayed between cells B6:B26 and the end time

between
cells c6:c26 for each respective carer.

I want the spread sheet to count the number of carers working between

the
start time entered in cells b28 and the end time entered in cell c28.

Note
that night carers may work, for instance, between 8 pm on one day and 8

am
on
the following day.

I have tried entering the formula
=COUNTIF(B6:B26,"=b28")-COUNTIF(C6:C26,"<=c28") but it does not seem to

work
for any time of day. Anyone have the answer to the formula I would use?







Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Count IF Multipile Formulas andreah New Users to Excel 2 June 23rd 05 12:44 PM
Count Position of Filtered TEXT cells in a column Sam via OfficeKB.com Excel Worksheet Functions 8 May 18th 05 04:23 AM
Count Position of Filtered TEXT cells in a column Sam via OfficeKB.com Excel Worksheet Functions 0 May 15th 05 08:14 PM
Conversion SVC Excel Worksheet Functions 9 February 28th 05 02:29 PM
SUMPRODUCT Formula to Count Row of data Below Matched Criteria Sam via OfficeKB.com Excel Worksheet Functions 8 February 3rd 05 01:37 AM


All times are GMT +1. The time now is 04:18 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"