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

Announcements
ALERT: QlikView server communication interruptions following Microsoft Windows Domain Controller security updates
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Regarding decisions


Hi All,

Greetings.

How do we decide when calculating  a parameter is it better to go with the calculatiions in the UI or to go for doing the same in the script?

Are there any scenarios?

Kindly let me know whats the best practice so that it does not affect the performance of the application.

Thanks in advance

Regards

Labels (1)
4 Replies
Anonymous
Not applicable
Author

Senthil

I always try and back things off into the script.

Best Regards,     Bill

nagaiank
Specialist III
Specialist III

If the calculations depend on the values selected, changed or entered by the user, they have to be done in the UI. In all other cases, it is preferable to do the calculations in the script for better performance. Even in cases where UI determines the result, it is better to identify which parts of the calculations are not dependent on user interaction and do them in the script so that on-the-fly calculations are kept to a minimum.

sspe
Creator II
Creator II

To add to the others, then it might be worth setting some "flags" in your LOAD script and then in your application do a SUM of these flags in order to calculate the result.

If you e.g. know that you always want to count the number of customers that have placed and order within the the last month, then you can add a "flag" in your LOAD script and set it to 1 if the customer has placed an order. In your application you can then add a SUM(FlagField) which will then give you the number of customers that have placed an order.
This will put some of the calculations to the script, but of course ther will stille be cases where this isn't enough and you'll have to calculate things on the fly.
Regards
Steen
Not applicable
Author

When I use set analysis, often I put some calculations in UI, otherwise all calculations go in script. But I don't believe that works for any qlikview user at despite this works for me.


Regards.