Forum Discussion
Create measure to filter data as per date selection by user
Hi there,
I have created a measure to filter data as per date, but want to make it dynamic by the ability to filter the data as per selected
- Anonymous5 years ago
Hi chavanr ,
As amitchandak mentioned——As long as it comes from same table or joined table, no need add that in filter clause
Please simply use the following formual:
Measure = CALCULATE(SUM(TCC_Kerbside[Gardenwaste Flag]),FILTER('TCC_Kerbside',[Gardenwaste Flag]=1))Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
3 Replies
- amitchandak
Super User
chavanr , You can use a slicer on the page from the month year from table TCC_Kerbside and that will filter
Or create a date table join it with date of TCC_Kerbside and have month year and other required column there and use that in slicer to filter
As long as it comes from same table or joined table, no need add that in filter clause
To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :radacad sqlbi My Video Series Appreciate your Kudos.
- mussaenda
Community Champion
Hi chavanr ,
try the selectedvalue function
CALCULATE( SUM(TCC_Kerbside[Gardenwaste Flag]), FILTER( (TCC_Kerbside), TCC_Kerbside[Gardenwaste Flag] = 1 ), FILTER( (TCC_Kerbside), TCC_Kerbside[Date Submitted Month Year] = SELECTEDVALUE(TCC_Kerbside[Date Submitted Month Year]) ) ) - AnonymousNot applicable
Hi chavanr ,
As amitchandak mentioned——As long as it comes from same table or joined table, no need add that in filter clause
Please simply use the following formual:
Measure = CALCULATE(SUM(TCC_Kerbside[Gardenwaste Flag]),FILTER('TCC_Kerbside',[Gardenwaste Flag]=1))Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.