Forum Discussion
summarized table with a dynamic filter Is it possible?
Anonymous
Try this code please:
March_Table = CALCULATETABLE( SUMMARIZE( Revenue_Data, [Country],[TERRITORY_DETAILED_DESCRIPTION],[BASE_AMOUNT],[DATE]) ,FILTER('Revenue_Data', year(Revenue_Data[DATE])= YEAR(SELECTEDVALUE(Revenue_Data[DATE]))-1) )________________________
If my answer was helpful, please click Accept it as the solution to help other members find it useful
Click on the Thumbs-Up icon if you like this reply ๐
5 Replies
- Fowmy
Super User
Anonymous
Try this code please:
March_Table = CALCULATETABLE( SUMMARIZE( Revenue_Data, [Country],[TERRITORY_DETAILED_DESCRIPTION],[BASE_AMOUNT],[DATE]) ,FILTER('Revenue_Data', year(Revenue_Data[DATE])= YEAR(SELECTEDVALUE(Revenue_Data[DATE]))-1) )________________________
If my answer was helpful, please click Accept it as the solution to help other members find it useful
Click on the Thumbs-Up icon if you like this reply ๐
- angelarojasmoraFrequent Visitor
Thanks! This was really useful
- Fowmy
Super User
Anonymous
if you are creating a calculated table, you cannot include the slicer values coming from your report. If you are going to use this code inside a measure, it will work.________________________
If my answer was helpful, please click Accept it as the solution to help other members find it useful
Click on the Thumbs-Up icon if you like this reply ๐
- AnonymousNot applicable
Ok Unfortunately not....yet... let me change it a wee bit.
March_Table =CALCULATETABLE(SUMMARIZE(Revenue_Data,[Country],[TERRITORY_DETAILED_DESCRIPTION],[BASE_AMOUNT],[DATE],Revenue_Data[FIN_YEAR]),FILTER('Revenue_Data',Revenue_Data[FIN_YEAR]= SELECTEDVALUE('Calendar'[FIN_YEAR])-1)So I'm trying this....I have on a page a slicer for financial year.... I shoose 2020 and i need that to be 2019 in the filter.. so the assumption is the selected value does this?there is a link the the calendar table from the original revenue_data table.I just can't get this to work...) - AnonymousNot applicable
ah...
So in a measure how will this look?