+ Reply to Thread
Results 1 to 11 of 11

Categorize time ranges and calculate events within the time period

  1. #1
    Registered User
    Join Date
    01-21-2017
    Location
    SRI LANKA
    MS-Off Ver
    2013
    Posts
    19

    Categorize time ranges and calculate events within the time period

    Dears


    I have a list of events (discharging / loading ) with a driver ID per particular event. each event has a date and time . My requirement is to categorize each time in to the time range ( if the date ,time is 07-Jul-19 10:39:22 then time range is 07-jul-19 10:00 - 11:00 ) and within the purticular time range how many events occurred by each driver ID. Appreciate your help. I have attached sample report .

    regards
    Yklanka
    Attached Files Attached Files

  2. #2
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,277

    Re: Categorize time ranges and calculate events within the time period

    With helper column in "J" with =MOD(H2,1) copy down till end

    "N4"
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Attached Files Attached Files


    atul


    If my answer (or that of other members) has helped you, please say "Thanks" by clicking the Add Reputation button at the foot of one of their posts.

    Also: if your problem is solved, please take the time to mark your thread as SOLVED by going to the top of your first post, selecting "Thread Tools" and then "Mark thread as solved".

  3. #3
    Registered User
    Join Date
    01-21-2017
    Location
    SRI LANKA
    MS-Off Ver
    2013
    Posts
    19

    Re: Categorize time ranges and calculate events within the time period

    Dear Athul

    Brilliant. Really appreciate your help !!

    Any possibility to auto fill the date , from time, to time and the driver ID in the summery . If yes, it would be really great.

    Best regards
    yklanka

  4. #4
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Categorize time ranges and calculate events within the time period

    For auto fill date
    In K5, L5, M5 then drag down

    =INT($K$4+M4)

    =L4+"01:00"

    =M4+"01:00"
    Attached Files Attached Files
    Pl note
    Array formula should be confirmed with Ctrl+Shift+Enter keys together.
    If answere is satisfactory press * to add reputation.

  5. #5
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,277

    Re: Categorize time ranges and calculate events within the time period

    Can you share some mock up data.

  6. #6
    Registered User
    Join Date
    01-21-2017
    Location
    SRI LANKA
    MS-Off Ver
    2013
    Posts
    19

    Re: Categorize time ranges and calculate events within the time period

    Hi

    thanks for the reply.

    I actually wanted to autofill the date as follows. if yardtime has 07-Jul-19 10:38:01 then to fill K4= 07-jul-19, L4=10:00, M4=11:00 as 10:38 will fall in within this time range. similarly , to analyse all times under yardtime and autofill date and time range.
    Attached Files Attached Files
    Last edited by yklanka; 08-08-2019 at 04:09 AM.

  7. #7
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,379

    Re: Categorize time ranges and calculate events within the time period

    Please manually mock up what you want in your workbook and post it again.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  8. #8
    Registered User
    Join Date
    01-21-2017
    Location
    SRI LANKA
    MS-Off Ver
    2013
    Posts
    19

    Re: Categorize time ranges and calculate events within the time period

    hi,attached.

  9. #9
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Categorize time ranges and calculate events within the time period

    PL see file.
    Column G and H were in text format. I changed into date time format.

    In K4, L4,M4

    =INT(MIN($H$2:$H$34))

    =FLOOR(MOD(MIN($H$2:$H$34),1),"1:00:00")

    =L4+"1:00"

    In N4 copied down to column Q

    =COUNTIFS($H$2:$H$34,">="&$K4+$L4,$H$2:$H$34,"<="&$K4+$M4,$F$2:$F$34,N$3,$I$2:$I$34,IF(N$2="Driver ID",O$2,N$2))
    Attached Files Attached Files
    Last edited by kvsrinivasamurthy; 08-08-2019 at 12:11 PM.

  10. #10
    Registered User
    Join Date
    01-21-2017
    Location
    SRI LANKA
    MS-Off Ver
    2013
    Posts
    19

    Re: Categorize time ranges and calculate events within the time period

    Dear kvsrinivasamurthy

    great work! many thanks and appreciate the help.

    best regards
    yklanka

  11. #11
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Categorize time ranges and calculate events within the time period

    Thanks for feed back.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Formula to calculate time between events
    By jeff0181 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-15-2018, 12:53 PM
  2. [SOLVED] Formula/method to sort by specific time period within date+time ranges in cell
    By mikeskins84 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 02-13-2018, 01:12 PM
  3. [SOLVED] Calculate the portion of a planned number during a period, based on another time period
    By BryGuy81 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-19-2017, 01:29 PM
  4. Replies: 12
    Last Post: 12-12-2012, 01:55 AM
  5. [SOLVED] Complicated:Calculate time period based on no. of units sold + fluctuations within period
    By omaha.crab in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-06-2012, 03:04 AM
  6. Replies: 2
    Last Post: 04-27-2011, 08:21 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1