Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Folks,
I need to create the Hourly Time Stamp in my Calender. I need to maintain Last 7 days Hourly timestamp date to Current rounded Timestap. Please find the below:
Date, Timestamp
11/5/2012, 11/5/2012 6:00:00
11/5/2012, 11/5/2012 7:00:00
11/5/2012, 11/5/2012 8:00:00
11/5/2012, 11/5/2012 9:00:00
11/5/2012, 11/5/2012 10:00:00
11/5/2012, 11/5/2012 11:00:00
11/5/2012, 11/5/2012 12:00:00
11/5/2012, 11/5/2012 13:00:00
11/5/2012, 11/5/2012 14:00:00
.
.
.
.
.
.
.
.
.
11/12/2012, 11/12/2012 14:00:00
11/12/2012, 11/12/2012 15:00:00
11/12/2012, 11/12/2012 16:00:00
11/12/2012, 11/12/2012 17:00:00
11/12/2012, 11/12/2012 18:00:00
The current Timestamp is: 11/12/2012 19:37:45 (11/12/2012 7:37:45 PM), so my last value 11/12/2012 18:00:00
if current Timestamp is: 11/12/2012 20:37:45 My last value 11/12/2012 119:00:00
The timestamp date starting with last 7th day early morning 6 AM and last value is rounded 1 Hr behind the current timestamp.
Is there any function avaliable in qlikview, to get the rounded timestamp value.
Please provide your thougts on this...
Thanks in Advance ......
Thanks,
Siri
Siri
This expression should do the trick:
=TimeStamp(Round(Value * 24) / 24)
(Change Value to the correct field name for your model).
Hope that helps
Jonathan
Corrected the expression