Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
komminenianusha
Partner - Contributor III
Partner - Contributor III

Number format issue

Hi All,

How to show field values in % format.I have one field which contains values like 20%,45%,2,4,55% etc.. when i select number format as % in qliksense it shows like 20%,45%,200%,400%,55% but its wrong i want to display like 20%,45%,2%,4%,55% etc.. 

Please help me for getting this. 

Thanks in advance.

 

Regards,

Anusha

1 Solution

Accepted Solutions
marksouzacosta
Partner - Creator II
Partner - Creator II

Hi Anusha,

You can use the code below as reference for your problem:

[TempOriginalValues]:
Load * Inline [
OriginalValue
20%
45%
2
4
55%
];

[Treatedvalues]:
Load
    [OriginalValue],
    Num(PurgeChar([OriginalValue],'%')/100,'#,##0%') AS [TreatedValue]
Resident
    [TempOriginalValues]
;

DROP TABLE [TempOriginalValues];

 

This will generate this result:

treatedvalues.png

Get hooked on Qlik at qlikbait.net

View solution in original post

3 Replies
agni_gold
Specialist III
Specialist III

Divide these numbers by 100 first and then select % as number format.
pradosh_thakur
Master II
Master II

purgechar(fieldname,'%')  

This is delete all the percentage fromthe number .

You can use

purgechar(fieldname,'%')  /100

and use number format as %

Learning never stops.
marksouzacosta
Partner - Creator II
Partner - Creator II

Hi Anusha,

You can use the code below as reference for your problem:

[TempOriginalValues]:
Load * Inline [
OriginalValue
20%
45%
2
4
55%
];

[Treatedvalues]:
Load
    [OriginalValue],
    Num(PurgeChar([OriginalValue],'%')/100,'#,##0%') AS [TreatedValue]
Resident
    [TempOriginalValues]
;

DROP TABLE [TempOriginalValues];

 

This will generate this result:

treatedvalues.png

Get hooked on Qlik at qlikbait.net