What is the best practice for sum up the time?
What is the best practice for sum up the time?
Hi,
I have a question on how to sum up a time (1 hour + 30 min + 2 hours) = 3 hours 30 min in Cross-Tabs. Any best practice available? What kind of data type I should use in SQL? datetime?
Thanks in advance for help
Regards,
John
I have a question on how to sum up a time (1 hour + 30 min + 2 hours) = 3 hours 30 min in Cross-Tabs. Any best practice available? What kind of data type I should use in SQL? datetime?
Thanks in advance for help
Regards,
John
What is the best practice for sum up the time?
Hello John,
Our report engine have SumTime aggregate function which you can find in report dictionary. This function accepts TimeSpan objects.
Thank you.
Our report engine have SumTime aggregate function which you can find in report dictionary. This function accepts TimeSpan objects.
Thank you.
What is the best practice for sum up the time?
I tried using itJan wrote:Hello John,
Our report engine have SumTime aggregate function which you can find in report dictionary. This function accepts TimeSpan objects.
Thank you.
{SumTime(reportTimeShift.tsd_value)}
return result is 0:00:00
I am not sure "reportTimeShift.tsd_value" how it should be, I store the value as bigint in sql. Any datatype conversion need to be done here?
What is the best practice for sum up the time?
Hello,
Yes of course you need convert your values to TimeSpan type, because SumTime function can work only with TimeSpan type. You can use following expression to convert your values to TimeSpan:
Thank you.
Yes of course you need convert your values to TimeSpan type, because SumTime function can work only with TimeSpan type. You can use following expression to convert your values to TimeSpan:
Code: Select all
TimeSpan.FromDays(double value)
TimeSpan.FromHours(double value)
TimeSpan.FromMilliseconds(double value)
TimeSpan.FromMinutes(double value)
TimeSpan.FromSeconds(double value)
TimeSpan.FromTicks(long value)
What is the best practice for sum up the time?
Well, I have another question on how to convert a time (sec) into hh:mm Format in Cross Tab.
I have a value like 27900 sec in Cross Tab, then I do function (27900/60)/60 instead of 7.75, it gave me 7.. this is not what I want
I wish there is a Converter that ca convert Sec to Hour/Min (hh:mm)
I have a value like 27900 sec in Cross Tab, then I do function (27900/60)/60 instead of 7.75, it gave me 7.. this is not what I want
I wish there is a Converter that ca convert Sec to Hour/Min (hh:mm)
What is the best practice for sum up the time?
Hello,
Thank you.
Code: Select all
TimeSpan.FromSeconds(value)
Re: What is the best practice for sum up the time?
Hello, i have a question of how to merge two same row and sum up time of that row which is diffrent. I am using Version 2020.1.1 from 18 December 2019, PHP, JS.
Re: What is the best practice for sum up the time?
I attached my report here please reply me as early as possible.
- Attachments
-
- summryreport1.mrt
- (26.27 KiB) Downloaded 186 times
-
- Posts: 6431
- Joined: Tue Mar 20, 2018 5:34 am
Re: What is the best practice for sum up the time?
Hello,
Sorry, maybe we did not exactly understand your question. Could you explain your issue in more detail?
Thank you.
Sorry, maybe we did not exactly understand your question. Could you explain your issue in more detail?
Thank you.