Forum Discussion
% slider to show % range
- 5 years ago
Hi mb0307
Not very clear about the result you want.
You said you have a PRODUCT master dim table with one-2-many relationship to Sales and Other tables. Do you want to filter through the product column in the PRODUCT table ?
If so, try this.
Measure_edit = var _product=SELECTEDVALUE('Product'[Product]) var _filtertable=FILTER(ALL('Sales Table'),'Sales Table'[Product]=_product&&[Column_%]>0) VAR _minrange=CALCULATE(MIN([Column_%]),_filtertable) var _maxrange=CALCULATE(MAX([Column_%]),_filtertable) return FORMAT(_minrange,"Percent")&"-"&FORMAT(_maxrange,"Percent")Best Regards,
Community Support Team _ Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
mb0307 , I doubt this can approched like this. You can have similat buckets like 50-80, not like one is 50-80 and another is 50 -75
If you want that then you need have one more column
new column =
var _min = minx(filter(Table, [Product] =earlier([product])),[%])
var _max = maxx(filter(Table, [Product] =earlier([product])),[%])
return // * 100 is optional
if(_min = _max, _max *100 & "" , _min & " " & _max)
better approch measure bucket
refer my video
Dynamic Segmentation, Bucketing or Binning: https://youtu.be/CuczXPj0N-k