Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Always 1 selected and Search

I have a qlikview tool that allows the user to search by either "Account Name" or "Account ID".

The amount of data has gotten to the point, that I want to make sure that always 1 is selected (either or/ or both).

When I make "Account Name" always 1 selected.  Then you can no longer search on Account ID, any value that comes up is greyed out, and when selected, it doesn't overwrite current value.  And vice versa with "Account ID"

For instance (see attached example)

Account Name = Beth is selected, which corresponds with account ID = 2.

Account Name is a "always one value selected field"

If someone searches for account ID = 6 (which is frank) I want them to be able to select it, and have it choose frank automatically.

Thanks for your help in advance!

1 Solution

Accepted Solutions
Not applicable
Author

That is wierd. I have used more complex trigger with a big dataset and it never happened. How big is your file?

There is a more simple way to do the same thing, but not sure if u r looking for more functionality with it. Select a default accountname and then on the clear button make it "Set clear state". No matter what u choose when u clear it , it always sets it back to that default accountname. Let me know if this helps.

View solution in original post

20 Replies
Not applicable
Author

there might be different ways .... below is one way

in script:

load AccountName,AccountID,dual(AccountName,AccountID) as Account;

load AccountName,AccountID from .... ;

in the app:

use the Account field for both text boxes one with text refresentation for account name another with expression num(Account) for accountid

alexandros17
Partner - Champion III
Partner - Champion III

try this ...

maxgro
MVP
MVP

perhasps with some trigger on the fields

see attachment

Not applicable
Author

Please check the trigger on - Account Name "on select".

Not applicable
Author

I am able to clear all filters, which is the issue.

The real document I'm working with has too much data to allow all values to be cleared.

I need to have the always one selected checkbox clicked for Account Name.

Not applicable
Author

I am able to clear all filters, which is an issue.  The document I'm working with is too large for every account to be available, so I need to have the Always Select One checkbox active on Account Name.  When I turn that functionality on, the trigger stops working.

Not applicable
Author

I need to have the Always select one checkbox active on Account Name, as there is too much data in my real tool, if they decide to clear all.  Once I add the functionality of always select one, then the trigger stops working.

Not applicable
Author

You dont have to make it "always one selected value", you can make that happen by using a trigger "on select" of account name, so even if u try to clear account name there will be only one selected value.

Not applicable
Author

Hi, sorry, I'm new to triggers.  In your example, I am able to "clear all".  Can you help me fix your example, so the functionality works, and they cannot clear all the filters?

For instance, open up your document, and then search for account 6.  After selecting it, hit clear all.