Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
Not applicable

Best practice with numbers question

Hi,

I have a application that loads EAN's, if I display these in a chart as is I get 9.0124571e+012, to display these correctly I have to use =num(EAN). I was wondering is it best to do this at load time or in the chart. Also is it best to tell QlikView what fields are numbers in the load or let it work it out itself, if it is best to let it know, what it the best way to do that.

Thanks,

Gavin.

Tags (2)
1 Solution

Accepted Solutions
MVP
MVP

Best practice with numbers question

Generally speaking, I try to get all of my values in the desired or most common format during the load. I like to do it explicitly in the script, but another approach is to go into settings, document properties, number tab, format it like you want it, and put a checkmark in "survive reload". Either way you do it, it's easier to format once than to format every time you need the value.

3 Replies
Not applicable

Best practice with numbers question

Hi Gavin

I would generally leave the load script to sort itself out because it's pretty good at doing that, the example you have identified above is one of the few times that I would force the load script to convert this to text, just because I wouldn't want to repeat the Num(EAN) expression every time I want to use it.

I have not used this before so you might want to check the syntax, but I think in the load script it would be something like:

LOAD Text(EAN) AS EAN_Ref

As I say, you might want to check the syntax of that one.....

Good luck,

MVP
MVP

Best practice with numbers question

Generally speaking, I try to get all of my values in the desired or most common format during the load. I like to do it explicitly in the script, but another approach is to go into settings, document properties, number tab, format it like you want it, and put a checkmark in "survive reload". Either way you do it, it's easier to format once than to format every time you need the value.

Not applicable

Best practice with numbers question

Thank you both for your advice,

Gavin

Community Browser