Forum Discussion

insandur's avatar
insandur
Helper II
2 years ago
Solved

Dynamic Indexing on Current day receiving time

Hi Experts😀,

 

I want to have a dyanamic index column based on recieving time of current day.

 

Eg. Every day i recieve 'Receieved Time' column and keeps changing everyday it might start from 5AM and next day it can be from 7 AM. Howverver i want to get index as 1 for starting hour like 5AM and 2 for next hour 6AM and so on.

 

Below are the reference table.

Received TimeRequired Index Next day it might beRequired Index
5/14/2024 5:001 5/15/2024 7:001
5/14/2024 6:002 5/15/2024 8:002
5/14/2024 7:003 5/15/2024 9:003
5/14/2024 8:004 5/15/2024 10:004
5/14/2024 9:005 5/15/2024 11:005
5/14/2024 10:006 5/15/2024 12:006
5/14/2024 11:007 5/15/2024  13:00:00 PM7
  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi insandur 

     

    If you only have one day's data in this table every day, you can change the "Received Time" column to Datetime type, sort table by "Received Time" column ascendingly, then add an Index column starting from 1. 

     

    Best Regards,
    Jing
    If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!

1 Reply

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi insandur 

     

    If you only have one day's data in this table every day, you can change the "Received Time" column to Datetime type, sort table by "Received Time" column ascendingly, then add an Index column starting from 1. 

     

    Best Regards,
    Jing
    If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!