Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
ivandrago
Creator II
Creator II

Convert to a Percent - Text Object

Hi,

I have the below formula which is in a Text Box but I want the result to be in a pecentage and in 2 decimal places i.e. 98.53%, Tried using the function num, but wasn't working and not sure if I was doing it the right way?

=1-(count({1<[Type]={'EXPECTED'}>} DISTINCT [ID])
/count({1<[Type]={'EXPECTED'}, [LP Flag]={0}>} DISTINCT [ID]))

Thanks

1 Solution

Accepted Solutions
Miguel_Angel_Baeyens

Hello,

Giving the Num() function a format should work

=Num(1-(count({1<[Type]={'EXPECTED'}>} DISTINCT [ID])/count({1<[Type]={'EXPECTED'}, [LP Flag]={0}>} DISTINCT [ID])), '#.##0,#0 %')


Note that in the format part I'm using "," as decimal separator and "." as thousand separator, and you may want to change that.

Hope this helps

View solution in original post

4 Replies
Miguel_Angel_Baeyens

Hello,

Giving the Num() function a format should work

=Num(1-(count({1<[Type]={'EXPECTED'}>} DISTINCT [ID])/count({1<[Type]={'EXPECTED'}, [LP Flag]={0}>} DISTINCT [ID])), '#.##0,#0 %')


Note that in the format part I'm using "," as decimal separator and "." as thousand separator, and you may want to change that.

Hope this helps

deepakk
Partner - Specialist III
Partner - Specialist III

hi,

use num function

num(1-(count({1<[Type]={'EXPECTED'}>} DISTINCT [ID])

/count({1<[Type]={'EXPECTED'}, [LP Flag]={0}>} DISTINCT [ID])) ,'#0.00%')

deepakk
Partner - Specialist III
Partner - Specialist III

Hi,

Me and Miguel pressed the post button at the same time.. and I lost by a fraction of seconds.. Wink

Not applicable

Yes,

it is always the same with Miguel. Big Smile

Looking forward to the weekend,

Roland