Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

edp
Contributor

About decimal separator

Hi,

I've got a variable manually set to 0.1: if I try to set the value by using a slider, its value changes in 0,1 (namely the slider changes the decimal separator from "." to ",") and the table which uses the variable doesn't work properly.

May anybody help me, please?

Thanks.

N.

6 Replies
rajeshvaswani77
Valued Contributor III

Re: About decimal separator

Hi,

Check this post.

community.qlik.com/thread/37183

thanks,

Rajesh Vaswani

Partner
Partner

Re: About decimal separator

Hi,

You can change the decimal separator for your document in the variables at the begining of the script:

SET DecimalSep='.';

Martin

edp
Contributor

Re: About decimal separator

Thanks for the reply: I'd like to keep my decimal separator as "," and I can't understand why the chart works with the variable set to "0.1" and not with "0,1" as setup by using the slider.

This is the formula:

=If(Rank( TOTAL [Distance (km)])=1, RGB(0,180,80) ,

    if(Rank( TOTAL [Distance(km)])<=Round(Count (TOTAL IDRun)*$(RankLimit)), RGB(200,240,210) ,

        if(Rank( TOTAL -[Distance(km)])=1, RGB(255,0,0) ,

            if(Rank( TOTAL -[Distance(km)])<=Round(Count (TOTAL IDRun)*$(RankLimit)), RGB(255,200,210)))))

Pls note that setting the variable to 0,1 Qlik shows me the error-underline as shown above.Error.jpg

Thks.

N.

morganaaron
Valued Contributor

Re: About decimal separator

Hi,

See this thread which I think encountered the same issue you're having - the solution was to wrap the variable in a num format command:

http://community.qlik.com/message/480852

Thanks.

mato32188
Contributor III

Re: About decimal separator

Hi edp,

you can try to use num(your value, '#,##0') instead of round.

BR

edp
Contributor

Re: About decimal separator

Right...the mistake was that I used the $(RankLimit) variable instead of the RankLimit variable: in the first case the value 0,1 doesn't work, in the second one it works properly.

Thank you to everybody for the help.

N.