Forum Discussion
How to create AND/OR filters
- 6 years ago
Hey Anonymous ,
acutally it's the other way around both slicers will work as AND.
In a somewhat simpliefied thinking one can compare the behavior of slicers that are origin from the same table as the Auto-Filter feat in Excel.
Regards,
Tom
Anonymous , AND is the default behavior. For Or you need one or 2 independent slicer
one sclicer -- for both -- independent
measure =
var _tf = maxx(slicer,slicer[value]) //independent table
return
calculate(countrows(Table), filter(Table, Table[FEAT1] =_tf || Table[FEAT3] =_tf))
// and
measure =
var _tf = maxx(slicer,slicer[value]) //independent table
return
calculate(countrows(Table), filter(Table, Table[FEAT1] =_tf && Table[FEAT3] =_tf))
Two sclicerw -- one for each -- independent
measure =
var _tf = maxx(slicer,slicer[value]) //independent table
var _tf1 = maxx(slicer1,slicer1[value]) //independent table
return
calculate(countrows(Table), filter(Table, Table[FEAT1] =_tf || Table[FEAT3] =_tf1))
// and
measure =
var _tf = maxx(slicer,slicer[value]) //independent table
var _tf1 = maxx(slicer1,slicer1[value]) //independent table
return
calculate(countrows(Table), filter(Table, Table[FEAT1] =_tf && Table[FEAT3] =_tf1))