Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I have one table.
Schedule:
Load
[Schedule Start],
[Schedule End]
From Schedules:
This time format of both fields is 'YY/MM/DD hh:mm:ss'
I need to find all the times between the start and end time eg:
[Schedule Start]=17/06/13 13:33:00
[Schedule End] =17/06/13 13:36:00
I would like my field to return :
TimeRange field:
17/06/13 13:33:00
17/06/13 13:34:00
17/06/13 13:35:00
My point is to show how long my schedule was running down to the minute level and maybe another field going to second level.
if there is an easier way to do this other than an interval match please advise.
Thank You
Sample script
Table:
LOAD *,
TimeStamp(Schedule_Start + ((IterNo()-1)/(24*60))) as TimeRange
While Schedule_Start + (IterNo()/(24*60)) <= Schedule_End;
LOAD * INLINE [
Schedule_Start, Schedule_End
17/06/13 13:33:00, 17/06/13 13:36:00
];
May be use a while loop here:
Sample script
Table:
LOAD *,
TimeStamp(Schedule_Start + ((IterNo()-1)/(24*60))) as TimeRange
While Schedule_Start + (IterNo()/(24*60)) <= Schedule_End;
LOAD * INLINE [
Schedule_Start, Schedule_End
17/06/13 13:33:00, 17/06/13 13:36:00
];
Thank You , if I wanted to go down to seconds would I Do the below?
Table:
LOAD *,
TimeStamp(Schedule_Start + ((IterNo()-1)/(24*3600))) as TimeRange
While Schedule_Start + (IterNo()/(24*3600)) <= Schedule_End;
LOAD * INLINE [
Schedule_Start, Schedule_End
17/06/13 13:33:00, 17/06/13 13:36:00
];
Yes, you got the trick