We have updated Flexmonster Software License Agreement, effective as of September 30, 2024. Learn more about what’s changed.

How to filter by excluding a value ?

Answered
Patrick TAVARIS asked on November 6, 2019

Hi,
I've a pivotTable with various data and I would like to exclude all lines that have a specific value for a given column.
I can do that by using the "filter" option on the given column header but I realized that it will not exclude the value but rather include all other checked values.
My problem here is that the dataset will be updated on a daily basis and new "authorized" values will be added for this column (values that I cannot know in advance).
So is there a feature to filter on column values list by excluding one or several values (instead of including ones) ? If not, are you planning to add this feature soon ?
 
Regards

3 answers

Public
Vera Didenko Vera Didenko Flexmonster November 6, 2019

Hello, 
 
Thank you for writing to us.
 
We are glad to inform you that it is possible to define only the members to be excluded via the exclude filter object property:

{
uniqueName: "Category",
filter: {
exclude: [
"category.[bakery]",
]
}
}

Here is a JSFiddle example for illustration: https://jsfiddle.net/flexmonster/6azg9emv/
 
Please let us know if this works.
 
Best Regards,
Vera

Public
Patrick TAVARIS November 6, 2019

Hi Vera,
Sorry but your answer is not resolving our issue 🙁
We are trying to filter using the user interface (filter popup), not using js code.
We was thinking about using the "labels" or "values" filtering but in the dropdown list there is no option "is empty". Only "contains, not contains, begins, equals ...".
We have tried the "equals" option with an empty value in the input text but it doesn't work.
 
Does our explanation are clear enough ?

Public
Vera Didenko Vera Didenko Flexmonster November 8, 2019

Hello,
 
Thank you for giving us some time.
 
Regarding filtering out empty cells, would you like to filter out empty measure cells on the grid or empty member cells in the headers?
Please refer to the following JSFiddle examples for illustration:
1) Example of empty header cells when an empty cell is marked as "(blank)": https://jsfiddle.net/flexmonster/xj8c43uq/
2) Example of empty header cells when an empty cell is marked as "": https://jsfiddle.net/flexmonster/y4xms2Lc/
3) Example of empty grid cells: https://jsfiddle.net/flexmonster/248nfskj/
 
Please let us know in which of the following scenarios you would like to filter out empty values.
This will help us to understand the situation better.
 
Waiting for your reply.
 
Best Regards,
Vera

Please login or Register to Submit Answer