Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Select in Field action on open not working

Hello all,

I have created the following trigger to select a value in my calendar when my app is opened:

=ONLY({$< [Check-in Date] = {'$(=DATE(vMaxUnofficialDate))'} >} [Check-in Week])

vMaxUnofficialDate is a variable created in the load script and I want the related Check-in Week to be selected whenever the app is opened. Providing no other date dimensions are selected when the app was last saved, the trigger works. However, if unrelated selections were made when last saved, the trigger won't override them. I have tried using Clear All as the first trigger - which clears all the selections - but the above trigger doesn't subsequently activate.

This trigger seems to work fine:

=YEAR(vMaxUnofficialDate)

So all I can assusme is that the problem is caused by using set analysis in the first trigger.

Has anybody else encountered this, and if so, have you found a solution?

Many thanks.

(Test app attached)



1 Solution

Accepted Solutions
Not applicable
Author

Hi there, you can clear selections within your set analysis, similar to these:

ONLY({$< [Check-in Date] = {'$(=DATE(vMaxUnofficialDate))'}, [Check-in Year]=, [Check-in Qtr]=>} [Check-in Week])

However, as I see, you have plenty user choices for temporality, so you may have a hard-time trying to clear all the selections within your set analysis, so I suggest you to ignore all the selection made by the user and work with the whole set of data:

ONLY({1< [Check-in Date] = {'$(=DATE(vMaxUnofficialDate))'} >} [Check-in Week])

Notice the only change in the set analysis was the replace of dollar-sign for 1. This works just as the clear all selections button.

Regards.

View solution in original post

2 Replies
Not applicable
Author

Hi there, you can clear selections within your set analysis, similar to these:

ONLY({$< [Check-in Date] = {'$(=DATE(vMaxUnofficialDate))'}, [Check-in Year]=, [Check-in Qtr]=>} [Check-in Week])

However, as I see, you have plenty user choices for temporality, so you may have a hard-time trying to clear all the selections within your set analysis, so I suggest you to ignore all the selection made by the user and work with the whole set of data:

ONLY({1< [Check-in Date] = {'$(=DATE(vMaxUnofficialDate))'} >} [Check-in Week])

Notice the only change in the set analysis was the replace of dollar-sign for 1. This works just as the clear all selections button.

Regards.

Not applicable
Author

Yes, that seems to do exactly what I need. Thanks.