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

Automatically select value(s) that another object selects?

Hi, I am new to Qlikview, as the company I work for recently started to promote QlikView.

Let's say there's TABLE1 with values(A,B,C,D,E) and TABLE2 with values(A,B,C,D,E, and others), and they are in the same format.

When some values of Table1 are selected, I want the same values to be selected in Table2.  No matter it's single selection or multiple.

I tried to use "Settings/Document Properties/Triggers" to set up a "OnSelect" action triggered by Table1's selection.

However I am struggling on how to compile the codes, because I want it to act dynamically, instead of manually setting up the connections by IF(TABLE1='A', TABLE2='A', IF(TABLE1='B', TABLE2='B', IF(...)))

Based on my limited programming experience (Excel VBA), my logics led me this way: Have a variable to store the selected value(s) of TABLE1. And, TABLE2 will be selected accoding to this variable.  But I feel this is going to complicate the problem...

訊息由此人編輯:Harry Wu

1 Solution

Accepted Solutions
sunny_talwar

You might be able to use a trigger with a search string like this:

='(' & Concat(DISTINCT '"' & FieldNameTABLE1 & '"', '|') & ')'

View solution in original post

2 Replies
sunny_talwar

You might be able to use a trigger with a search string like this:

='(' & Concat(DISTINCT '"' & FieldNameTABLE1 & '"', '|') & ')'

harrywu1
Contributor III
Contributor III
Author

Thanks! This is just amazing! It works!

It looks like a string combination of TABLE1, and TABLE2 adopts this combined string to select automatically itself.

I will take some time to learn the used functions of "Concat" & "DISTINCT", to figure out how this works.

Thanks again!