Announcements
cancel
Showing results for
Did you mean:
Partner - Creator

## Time stamp to Hours is not extracting properly

Hi All,

I am trying to extract the 24 hour time from a timestamp Date Time

example ;

,Time(round(frac([TransCont DateTime]),1/24), 'hh') as [TransCount 24 Hours]

but the the table is showing

TransCont DateTime TransCount 24 Hours
1/04/2011 10:23 AM10
1/04/2011 10:24 AM10
1/04/2011 10:25 AM10
1/04/2011 10:26 AM10
1/04/2011 10:27 AM10
1/04/2011 10:28 AM10
1/04/2011 10:29 AM10
1/04/2011 10:30 AM11
1/04/2011 10:31 AM11
1/04/2011 10:32 AM11
1/04/2011 10:33 AM11
1/04/2011 10:34 AM11
1/04/2011 10:35 AM11
1/04/2011 10:36 AM11

I noticed its converting 9.30-10.30 as 10  and  10.30-11.30 as 11.

Please anyone  got any idea? how can i create a correct table

1 Solution

Accepted Solutions

That's because you are using round(), and those appear to be correct rounding. If you just want the hour, use:

hour([TransCont DateTime])

-Rob

4 Replies

That's because you are using round(), and those appear to be correct rounding. If you just want the hour, use:

hour([TransCont DateTime])

-Rob

Luminary Alumni

Hi Prasanna,

Below script working for me, please check

Hour(TimeStamp#(TimeStam, 'M/D/YYYY hh:mm tt' )) AS Hour

Regards,

Jagan.

Partner - Creator
Author

Thank you Rob,

It worked.

Creator
1. Name the Second sheet as ‘Dashboard’ and display the following information –
• Productive and Nonproductive Hrs. for each week
• Number of Employees present each day of the month per supervisor
• Avg. Time Spent by Employee on Floor
• Calculate Team Utilization (use formula -Total time/Number of days per activity )