Skip to main content
Announcements
July 15, NEW Customer Portal: Initial launch will improve how you submit Support Cases. IMPORTANT DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
juriengroot
Contributor III
Contributor III

Default value for pick match

Hi,

I am using a pick and match formula with a dimension (not a variable) and I'd like to show a default value if no value is picked.

$(=Pick(Match((Grouping1),'Option1',

'Option2')

,'[Option1]'

,'[Option2]'

))

I thought of something like:

if(Count(Grouping1)=1, $(=Pick(Match((Grouping1),'Option1',

'Option2')

,'[Option1]'

,'[Option2]'

)),Option1)

Anyone knows the right syntax for it?

11 Replies
marcus_sommer

For me it worked well - just tested (whereby in qlikview).

- Marcus

kl23
Contributor
Contributor

Just do

Pick( 1+Match( someField, baseVal1, baseVal2 ),  convertVal_default, convertVal1, convertVal2 )

Match returns 0 when no items matches. Plus 1 to shift it back, such that Pick get you the first item as default when no match is found.