QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
QlikWorld 2022, LIVE in Denver CO., May 16-19, 2022. REGISTER NOW TO RECEIVE EARLY BIRD PRICING
cancel
Showing results for
Did you mean:  Creator

Convert minutes into hour with decimal

Hi,

I have two timestamp fields. For example, Datetime_Start and Datetime_End.

First, I want to calculate the difference in minutes between these fields. I am able to achieve using below expression,

Interval((Datetime_End - Datetime_Start ),'mm').

Now, i want to convert that difference into hours with two decimal value. For example, If we have difference is 881in minutes, then i should get 14.68 (881/60). But it shows other value like, 0.01020755.

Why it is happening like this? Is it because the value already in minutes? In this case, how do we change into number before convert into hour with decimals.

I am using QlikView 10 SR3 version. Please let me know. Thanks in advance.

Regards,

Durai.

1 Solution

Accepted Solutions  MVP

The current values are fractions of one day -- which is how times are stored. To convert to hours with two decimals, the conversion would be:

round( (Datetime_End - Datetime_Start ) / (1/24), .01)

-Rob

3 Replies  MVP

The current values are fractions of one day -- which is how times are stored. To convert to hours with two decimals, the conversion would be:

round( (Datetime_End - Datetime_Start ) / (1/24), .01)

-Rob  Creator
Author

Thanks Rob. It works!!!  Contributor
Thanks, I was searching this solution by several hours Community Browser