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: 
Remco
Contributor III
Contributor III

Question about filtering 2 alternate states with one dimension

Hi all!

I have one simple plain dataset, I have filter A with State A and filter B with State B

In table A I have State A select and a simple measure sum gives me the correct sum for each filter set in Filter A and

for table B the same goes, all perfect. In a graph I compare Result A with Result B using Sum({[State A]}RESULT) and for the result for B the same, Sum({[State B]}RESULT). Also this works well.

In the graph there is a dimension, EndYear, that splits up the results per year. Now I come the question:

1) How can I  create a filterpane that 1) only shows those EndYears that are in filtered set A and B and 2) make the graph filter on that dimension?

 

Capture.png

 Thanks!

Labels (4)
1 Solution

Accepted Solutions
ogster1974
Partner - Master II
Partner - Master II

using 

EndYear = $::EndYear

 

View solution in original post

7 Replies
ogster1974
Partner - Master II
Partner - Master II

As a guess try

only({[State A] * [State B]} EndYear)

Remco
Contributor III
Contributor III
Author

Hi, thanks for trying, it returns 'Invalid Dimension'...

Remco
Contributor III
Contributor III
Author

I managed to get the table for filtering correctly filled, partly with your hint. It works with:

=aggr(only({[State A] + [State B]} [EndYear]),[EndYear])

But now how to apply the filter on the graph with the selected value out of that table?

 

ogster1974
Partner - Master II
Partner - Master II

using 

EndYear = $::EndYear

 

Remco
Contributor III
Contributor III
Author

You mean, as filter on the measures in the graph?

Remco
Contributor III
Contributor III
Author

OK, I found it:

 

Sum({[State B]<EndYear = $::EndYear>})

 

and

 

Sum({[State A]<EndYear = $::EndYear>})

 

Thanks

ogster1974
Partner - Master II
Partner - Master II

Your welcome