Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello everybody! Why is that if I use this visual: , and insert there the "date of sale" of my data, it segments this visual
, but if I insert there a DAX formula: "filter= DATESINPERIOD(Sales[Date of sale],(TODAY()-90),-9,MONTH).", it doesnt filter my
?
Solved! Go to Solution.
Thanks for the reply from @Gaga_Jin and @Ronak131290 , please allow me to provide another insight:
Hi @Orlovaaaa ,
According to your formula, do you want the table VISUAL to be dynamically filtered by date based on minimum date (TODAY()-90),-9,MONTH),maximum date (TODAY()-90))
Here are the steps you can follow:
1. Create measure.
Flag =
var _today=TODAY()
var _maxdate=_today - 90
var _mindate=DATE(YEAR(_maxdate),MONTH(_maxdate)-9,DAY(_maxdate))
return
IF(
MAX('Table'[Date]) >= _mindate&&MAX('Table'[Date])<=_maxdate,1,0)
2. Place [Flag]in Filters, set is=1, apply filter.
3. Result:
If the results above don't meet your expectations, Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data. We can better understand the problem and help you
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Thanks for the reply from @Gaga_Jin and @Ronak131290 , please allow me to provide another insight:
Hi @Orlovaaaa ,
According to your formula, do you want the table VISUAL to be dynamically filtered by date based on minimum date (TODAY()-90),-9,MONTH),maximum date (TODAY()-90))
Here are the steps you can follow:
1. Create measure.
Flag =
var _today=TODAY()
var _maxdate=_today - 90
var _mindate=DATE(YEAR(_maxdate),MONTH(_maxdate)-9,DAY(_maxdate))
return
IF(
MAX('Table'[Date]) >= _mindate&&MAX('Table'[Date])<=_maxdate,1,0)
2. Place [Flag]in Filters, set is=1, apply filter.
3. Result:
If the results above don't meet your expectations, Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data. We can better understand the problem and help you
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Thank you @Anonymous ! Your answer definitely helps and its a very interesting approach. Finally could get the problem solved.
@Orlovaaaa , hi
i think it's not working because you are using this dax formula to create measure.
just create new table from "modeling" section in power BI, write a dax fromula like this:
Thank you!
Hello Orlovaaaa,
Required More imformation about you issue.
Need more clrification for your issue.
Thank you
User | Count |
---|---|
25 | |
12 | |
8 | |
7 | |
7 |
User | Count |
---|---|
25 | |
12 | |
11 | |
10 | |
6 |