Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
peterderrington
Creator II
Creator II

Only display certain Dimension Values

I have a straight Table and only want to display certain dimension values within it.

 

I tried this expression as a Conditional within the dimensions section but it didn't get rid of the other months:

=if(MonthYear<>'Apr 2020''May 2020''Jun 2020''Jul 2020''Aug 2020''Sep 2020''Oct 2020''Nov 2020',MonthYear)

Any ideas?

Thanks.

1 Solution

Accepted Solutions
richard_chilvers
Specialist
Specialist

I'm not sure you can use not equals in this way in Qlik. Assuming the values are correct for your field called MonthYear, I'd use the MATCH function, ie:
=IF(MATCH(MonthYear, 'Apr 2020', 'May 2020' ......)=0, MonthYear)

View solution in original post

3 Replies
Nicole-Smith

This should work (you want it as the dimension, not the conditional--the condition shows/hides the entire column, not values within it):
=if(not match(MonthYear,'Apr 2020','May 2020','Jun 2020','Jul 2020','Aug 2020','Sep 2020','Oct 2020','Nov 2020'), MonthYear)

peterderrington
Creator II
Creator II
Author

Thanks for this, i had to drop the "not" function so it would only show the months in the expression (which is what i wanted - sorry if i didnt explain that properly) however there now seems to be an extra line in the dimensions plus the order isnt right which i tried to solve with a Match expression in the Sort tab but no difference. Sure i'm missing something obvious. 

richard_chilvers
Specialist
Specialist

I'm not sure you can use not equals in this way in Qlik. Assuming the values are correct for your field called MonthYear, I'd use the MATCH function, ie:
=IF(MATCH(MonthYear, 'Apr 2020', 'May 2020' ......)=0, MonthYear)