4 Replies Latest reply: Mar 30, 2018 9:54 AM by Massimo Favaro

# Changing measure number formatting changes value

Hello everyone,

I am experiencing a strange issue.

I have calculated a measure that's like:

SUM(INTERVAL(EndingDate - StartingDate, 'h')) that should measure the sum, in hours, of the duration of some kind of processes.

No problems this far.

I then created some visualizations, for example a KPI: it shows me 9400.

Nice, but I'd like to show the separator of the thousands. So I edit the KPI, find the measure and change the formatting, changing if from "Automatic" to "Number".

Nice, now it should show me 9.400...nope. It shows me 391,67 that is 9400/24, it's changing it from hours to days.

Why does it so?
And how can I format the measure?
I've read https://help.qlik.com/it-IT/sense/September2017/Subsystems/Hub/Content/Scripting/FormattingFunctions/formatting-function… but it's not very intuitive.

Should I measure it in days, formatting it as number and multiply the measure by 24?

• ###### Re: Changing measure number formatting changes value

Maybe something like

num (   sum ( EndingDate - StartingDate ) * 24   , '#,##0' )

• ###### Re: Changing measure number formatting changes value

I tried changing to SUM(INTERVAL(EndingDate - StartingDate, 'd')) and it shows the same results.

I guess I'll have to use your formula...

Thanks

• ###### Re: Changing measure number formatting changes value

If you want to use the Interval() function, then as that will be doing the formatting try putting the Interval() as outer part of your expression :

Interval ( Sum ( EndingDate - StartingDate ) , 'd' )

• ###### Re: Changing measure number formatting changes value

It seems to cause no differences...