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

what is a match function?

hi friend's please tell me any one what is a match function with example

5 Replies
arulsettu
Master III
Master III

hi

The match function performs a case sensitive comparison.

for ex

if you have list of countries. requirement is display ex: india, usa, canada, uk alone.

for that

if(match(country, 'india', 'usa', 'canada', 'uk'),country)

will give the result

hope it helps

Not applicable
Author

than q sir

arulsettu
Master III
Master III

if answer is correct please close the thread it would be helpful to others

MK_QSL
MVP
MVP

Arul has already replied on your post... But I would advice you to ready the QlikView reference manual before posting such a basic question. Also, you can search on QlikCommunity for previous questions on same topics. This would help you to get answer without waiting .....

Particular to this topic, you can also check WildMatch and MixMatch functions.. ...

match( str, expr1 [ , expr2,...exprN ] )

The match function performs a case sensitive comparison.

Example:

match( M, 'Jan','Feb','Mar')

returns 2 if M = Feb

returns 0 if M = Apr or jan

mixmatch( str, expr1 [ , expr2,...exprN ] )

The mixmatch function performs a case insensitive comparison.

Example:

mixmatch( M, 'Jan','Feb','Mar')

returns 1 if M = jan

wildmatch( str, expr1 [ , expr2,...exprN ] )

The wildmatch function performs a case insensitive comparison and permits the use of wildcard characters ( * and ?) in the comparison strings.

Example:

wildmatch( M, 'ja*','fe?','mar')

returns 1 if M = January

returns 2 if M = fex

arixooo123
Creator III
Creator III

I have used that for sorting different values of an attribute in charts

=match(attribute,'value1','value2',....)