Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Help with input box

Hi All,

I have a Actual column and Target column for each person. I am providing a input box where user can enter the % value which is Actual/Target. Now based on the % value entered by the user in input box, I need to filter out the Persons for whom Actual/Target = %(entered in input box) in a variable.

Can  anyone help me with this.

Thanks,

Niharika.

1 Solution

Accepted Solutions
petter
Partner - Champion III
Partner - Champion III

Some extra logic in an additional variable will help. Have a look at this. BTW you can exclude the vMatch variable from the Input Box. It will still work correctly.

View solution in original post

14 Replies
swuehl
MVP
MVP

Try creating a calculated dimension (e.g. a field expression in a list box), like

=Aggr( If( Only({1} Actual / Target) >= vVariable, Only({1}Person)), Person)

avinashelite

create a variable to capture the input of the user than in the expression use the variable like this

Add Actual & Target as the dimension and the expression

Expression 1 :

Name : value

Actual/Target


Add one more expression

Expression 2:

if( value = variable , value )

Go to >presentation tab and hide the first expression

sacosta5
Contributor III
Contributor III

Hi...

check this...

Inputfield example.qvw

Anonymous
Not applicable
Author

Thanks everyone,

The solutions provided can be used for one particular chart. But I have 10 charts of different KPI's and all these 10 charts should show data of the person's whose Actual /Target is the value entered in input box. So I need the persons for whom the condition gets satisfied in a variable, which I can use for all the 10 charts in set analysis.

swuehl
MVP
MVP

The set analysis might look like

=Sum( {<Person = {"=Actual / Target >= vVariable"}>} Value)

Anonymous
Not applicable
Author

HI Swuehl,

Thanks for the response, but I am not getting any data when I keep the expression you have suggested.

Any other solution?

swuehl
MVP
MVP

If you have more than one record per Person containing Actual and Target, we need to aggregate:

=Sum( {<Person = {"=Sum(Actual) / Sum(Target)  >= vVariable"}>} Value)


vVariable is the variable that holds the percentage threshold. There need to be persons that fulfill the requirement, of course.

Anonymous
Not applicable
Author

Hi All,

Let me put my requirement in a more clear way. I have 2 tables as

Table1:

PersonYearActualTarget
Person120158086
Person2201578100
Person320153754
Person4201588150
Person520155860
Person120166080
Person220163057
Person320166590
Person4201652100
Person5201675100

and Table2:

PersonYearQty
Person1201547
Person2201522
Person3201520
Person4201533
Person5201516
Person1201635
Person2201644
Person3201644
Person4201638
Person5201612

Now in Qlikview, I will give an input where user can give a value and there are two different charts one showing Actuals and the other showing Qty.

Suppose when user enters 75 in input box, in both the charts(showing Actuals and Qty), the details of only those persons for whom (Actual/Dropped)*100=75 should be shown.

Similarly there would be totally 10 different charts where the same compression should happen.

petter
Partner - Champion III
Partner - Champion III

The expession to use goes like this:

Sum( { < %Key = { "=Actual/Target=$(vPercent)/100" } > }  Actual )

Have a look at this which is a screenshot of the included QVW example application:

2016-03-09 #1.PNG

To be sure that you hit the right interval you should do a Round()-function since the division might not be totally accurate.