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

Creating buttons with multiple actions and selections

Hi guys,

An awkward one I think.

I have a set of Purchase Order data. I am trying to filter out all of the unwanted material types leaving me with just raw materials.

The problem is there are three different fields that contain the information I need (largely using free text!) and they aren't necessarily in sync with each other!

Therefore, I'm trying to create a button that will firstly filter out all of the unwanted materials based on a search string in one field. Then once done, I want the button to then search in another field among the "unwanted" data using another search string and add these into the pulled data. I then need to repeat this action on another field among the "unwanted" data.

Any ideas?

I can get them all to work seperately but trying to combine them in the desired order above is proving somewhat taxing.

EDIT - I have attached a dummy example. In this, I'm trying to return all of the countries from the Eastern Bloc in the "Country of Club" column, then adding either Barcelona or Real Madrid into the data set and then finally Johan Cruijff into the data set.

Thanks,

Gareth

1 Solution

Accepted Solutions
effinty2112
Master
Master

Hi Gareth,

                    You can add a listbox with this expression:

=aggr(if(Match([Country of Club],'Czech Republic','Hungary','Russia','Ukraine') or Match(Club,'Barcelona','Real Madrid') or Match([Player Name], 'Johan Cruijff'), 'Yes','No'),Club)

This is okay for small data sets. In general it would be better to create a flag in the appropriate table (the granularity is the important consideration) in your load script.

cheers

Andrew

View solution in original post

5 Replies
avinashelite

Are the fields linked to each other ? if yes once you made the selection you could add the lock feature and then choose the data from another filed ....share the sample data with the desired output will try to help you

Anonymous
Not applicable
Author

Hi Avinash,

I have just amended my original post with some sample data and a desired output


Cheers,

Gareth

effinty2112
Master
Master

Hi Gareth,

                    You can add a listbox with this expression:

=aggr(if(Match([Country of Club],'Czech Republic','Hungary','Russia','Ukraine') or Match(Club,'Barcelona','Real Madrid') or Match([Player Name], 'Johan Cruijff'), 'Yes','No'),Club)

This is okay for small data sets. In general it would be better to create a flag in the appropriate table (the granularity is the important consideration) in your load script.

cheers

Andrew

Anonymous
Not applicable
Author

Thanks Andrew,

That's a good way of doing it.

Out of interest, if under Country of Club I have Korea (North) and Korea (South), how would I write them in the expression as currently it doesn't like it due to the brackets.

Cheers,

Gareth

Anonymous
Not applicable
Author

Hi Andrew,


Is there a way of incorporating wildcard searches into this, so for instance if I wanted it to also pull back all records in the Player Name column that contain "Ronald". So results in that column would be Ronaldo, Cristiano Ronaldo and Ronaldinho.

Cheers,

Gareth