Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello All,
I am having two fields say, StartTime & EndTime. Now I am creating EndTime-StartTime as SessionDuration. But with this expression values are repeating like if a session was of 30 min then it is repeating 2 times which should not happened.
Is it require any function?
Regards,
Balraj
Hi Balraj,
Can you kindly provide us the sample data, so that we can trace the exact problem and work for the solution.
Regards,
@vi
Hi Balraj,
I didn't get ur problem clearly.
Anyway, u should not subtract anything if it is a period field (Example, Date, Time etc)
U should use
Interval(EndTime - StartTime, 'HH:MM:SS')
Thanks,
Use Interval function or may be use it with the primary key values suppose if there are different keys but duration is same like
Key, Duration
4, 30 Min
5, 30 Min
5, 20 Min
Ex:-
Load
Id as %Key,
StartTime,
EndTime,
Interval(EndTime - StartTime, 'hh:mm:ss') as Duration
From Location;