Forum Discussion
Calculating same measure with different filter context
- 3 years ago
Hey preetjawaria ,
your requirement can not be solved having only a single table, this due to the concept of Auto-Exist: Understanding DAX Auto-Exist - SQLBI
My recommendation is to create a proper star schema with separate Dimension Tables Account and Bill, you might also consider creating two fact tables one for BILL and one for ACCOUNT.
Regards,
Tom
Hi preetjawaria ,
Approve with TomMartens , If you want to achieve this, you may need to create a new table.
Please try:
First create a new table for slicer:
Then use the two columns to create two slicers
Apply the measures:
Measure For Acct Name = CALCULATE(SUM('Table'[Report Count]),FILTER('Table',[Acct Name]=SELECTEDVALUE('For slicer'[Acct Name])))
Measure For Bill Name = CALCULATE(SUM('Table'[Report Count]),FILTER('Table',[Bill Name]=SELECTEDVALUE('For slicer'[Bill Name])))
Total = [Measure For Acct Name]+[Measure For Bill Name]
Final output:
Best Regards,
Jianbo Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- preetjawaria3 years agoFrequent Visitor
Thanks for the inputs. everyone.