Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Contributor
Contributor

Num# conversion not working (format code)

Hi,

I need to convert the following Strings to Numbers:

Unbenannt.PNG

I also want to remove the decimal place after the "," (It is always 000)

For the thousands separator, i want to show a comma instead of the "."

Example: Current String: 80.000,000 --> Expected Number: 80,000

Example 2: Current String: 200,000 --> Expected Number: 200

As I tried to understand, the right way to do this is something like that in the loading script :

Num#(CURRENTMAX,'#.#', ',', '.') as NEUMAX

I understood that the '#' operator denotes a possible digit to the left of the decimal point.
What is the right format code to get things working?

Thanks in advance! 😊

 

1 Solution

Accepted Solutions
Highlighted
Contributor II
Contributor II

You can adjust with the num function, but note that this is a mask:
=num(num#(CURRENTMAX, '#.## 0,000', ',', '.'), '#,##0')

You can also round off the number to make the decimal places disappear:
=floor(num#(CURRENTMAX, '#.##0,000', ',', '.'))
After this you apply num function

View solution in original post

2 Replies
Highlighted
Creator II
Creator II

Hi

If you are sure that your input is going to be in the format shown you could try the following

 

Replace(Replace(CURRENTMAX,',000',''),'.',',') ) as NEUMAX

 

Regards

Adrian

Highlighted
Contributor II
Contributor II

You can adjust with the num function, but note that this is a mask:
=num(num#(CURRENTMAX, '#.## 0,000', ',', '.'), '#,##0')

You can also round off the number to make the decimal places disappear:
=floor(num#(CURRENTMAX, '#.##0,000', ',', '.'))
After this you apply num function

View solution in original post