Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Script/Expression Help Required

Hi!

I’m trying to create a graphic with the following expressions:

  1. Sum of business retributions of the business selected in a input box (Select Business);
  2. Average of business retributions of the benchmark selected in a list box (Select Benchmark).

        If user chooses:

    • Option 1 – I consider only business number 4 and 95;
    • Option2 – I consider only business number 112 and 95;
    • Option 3 – I consider retribution of business number 112 and 4;

      This a very simple example, but I need to create a benchmark with a lot of lists of business and connect the user choice to my      average graphic expression. I think to insert these benchmarks in a list box.

     If I want to calculate the average of retribution fields of all my business records,  is it correct the use of this simple
     expression:
  =avg(retribuzione+contributi+straordinario+inail)

Moreover,I’d like to create a label to show the business selected and the name of benchmark chosen for the average.

I try to use these variable:  “vBusiness “ forbusiness selected and  “vBenchmark” for benchmark option selected.

You can find an example attached.

Do you think it’s possible to do?

Any suggestions greatly appreciated.

Andrea

11 Replies
jerem1234
Specialist II
Specialist II

count(distinct azienda) should do it. The azienda field is linked with the Options, so a simple count should do.

If your question for this discussion has been answered, could you mark any posts that were correct/helpful? Just so we can close this discussion and so it may help others that search for the same thing.

Hope this helps!

Not applicable
Author

thank you!