Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
dselgo_eidex
Partner - Creator III
Partner - Creator III

Select in Field action, select no values

Hello, I have a variable that can either contain a search string or be blank. I have a button that uses the Select in Field action to apply this search string to a field. However, when the search string is empty, the action will select all of the possible values instead of not selecting any. I figure I can do this using a macro, but I'd like to know if it is possible within the list of actions.

1 Solution

Accepted Solutions
dselgo_eidex
Partner - Creator III
Partner - Creator III
Author

Actually, I figured out my issue. When my search string was supposed to be NULL, it was actually (""). This caused the Select in Field to select all values which matched that search string, which was every possible value. I adjusted the search string to actually be set to NULL and it now works fine.

Sorry, should've waited a bit before posting this question.

View solution in original post

7 Replies
Anil_Babu_Samineni

How you are define the search string in your action of the object?

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
dselgo_eidex
Partner - Creator III
Partner - Creator III
Author

The search string is set up like ("A"|"B"|"C"). It is stored into a variable, so my action is:

Select in Field

Field

vSearchString

There is a case where vSearchString will equal null, and I don't want any values to be selected, but the action seems to be selecting all of the possible values anyway.

sunny_talwar

Would you be able to share a sample to check out the issue?

dselgo_eidex
Partner - Creator III
Partner - Creator III
Author

Actually, I figured out my issue. When my search string was supposed to be NULL, it was actually (""). This caused the Select in Field to select all values which matched that search string, which was every possible value. I adjusted the search string to actually be set to NULL and it now works fine.

Sorry, should've waited a bit before posting this question.

antoniotiman
Master III
Master III

Hi Danny,

try this :

Select in Field ->  Field :

=If(Len(Trim(vSearchString)) > 0,'Your Field')

Regards,

Antonio

Anil_Babu_Samineni

You can use like below   ("A"|"B"|"C"|"")

Capture.PNG

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
sunny_talwar

Please mark your own response as correct to close this thread.

Best,

Sunny