Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
nareshthavidishetty
Creator III
Creator III

dynamic Expression

Hi all ,

I got a requirement like there are process and Quality check

process       Quality check threshold will be

x                      98%

y                      98%

z                      95%

a                       95%

b                       95%

c                       98%

so I'm showing that in straight table these things   now my question is

if I select process x,or y or c it should show 98% dynamically

and if I select z it should show 95%

how can I achieve this

I can write a condition in expression(background color)    if it is only 98% but here it is changing to 98 or 95

17 Replies
jyothish8807
Master II
Master II

Hi Naresh,

Try like this:

Dim: Process

expression:

Count([Quality check] / count({1}total [Quality check])

Br,

KC

Best Regards,
KC
nareshthavidishetty
Creator III
Creator III
Author

Hi I'm not counting here I want that 98% or 95% should be shown if I select process x,y but here threshold values are consistent they are changing on process level

Anil_Babu_Samineni

Share your Application?

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
nareshthavidishetty
Creator III
Creator III
Author

hi

cannot share the application nda

if u want I can provide more details

Anil_Babu_Samineni

Application, Means not the real directory Data. Try to create scramble data. This also not possible

Can i know what expression you are using this Quality check threshold will be

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Not applicable

Hi Naresh ,

I did not get the exact requirement but its better if you store these values in a variable , so that the they are not affected by a change in selection .

Hope this helps .

Regards,

Shantanu

jyothish8807
Master II
Master II

Hi Naresh,

Then Try expression like below:

if(Process='X','98%',if(Process='Y','98%'))

Is this what you are looking for. Now the values will be constant for each process.

Regards

KC

Best Regards,
KC
nareshthavidishetty
Creator III
Creator III
Author

sum({<Activity={Quality Check},Year={$(vCurrYear)},Month={$(vCurrMonth)}>}No_Of_Items)-(sum({<Activity={External error},Year={$(vCurrYear)},Month={$(vCurrMonth)}>}No_Of_Items)))/sum({<Activity={Quality Check},Year={$(vCurrYear)},Month={$(vCurrMonth)}>} No_Of_Items)

for the calculation Quality%

jyothish8807
Master II
Master II

Hi Naresh,

Your requirement is not clear.

Its obvious that if the threshold value changes then the expression value will also change.

Try this also.

sum({<Activity={Quality Check},Year={$(vCurrYear)},Month={$(vCurrMonth)}>}No_Of_Items)-(sum({<Activity={External error},Year={$(vCurrYear)},Month={$(vCurrMonth)}>}No_Of_Items)))

/

sum({1<Activity={Quality Check},Year={$(vCurrYear)},Month={$(vCurrMonth)}>}total No_Of_Items)

Br,

KC

Best Regards,
KC