Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Using slicer in summarised table

I have below DAX:

 

SUMMARIZE(Filter(Table ,Table[type trans]="Invoice")
, Table[As of Date]
, Table[account_cd]
, "DBE", if([Measure 01]>0,[Measure 01],blank()), "CRE", if([Measure 01]<0,[Measure 01],BLANK()))

 

I want to use type trans as a slicer and take values from it rather than hardcoding. How to do that ?

 

4 REPLIES 4
Anonymous
Not applicable

I performed summarise inside a measure and its now working

AllisonKennedy
Super User
Super User

Why do you need the SUMMARIZE table? Can you just put the columns in a matrix and create a measure:

 

DBE= if([Measure 01]>0,[Measure 01],blank()), "CRE", if([Measure 01]<0,[Measure 01],BLANK())

 

Then use Type Trans as a slicer.

 

Has this post solved your problem? Please mark it as a solution so that others can find it quickly and to let the community know your problem has been solved. 

 

If you found this post helpful, please give Kudos.

I work as a trainer and consultant for Microsoft 365, specialising in Power BI and Power Query. 

https://sites.google.com/site/allisonkennedycv


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

Anonymous
Not applicable

Account code cannot be used in table since we require table in summarised format.

 

Measure 01 has positive and negative values , positive ones has to be grouped under debit and negative under credit based on As of date and account cd.

Measure 01 has following DAX = Sum(Table[Amount]) , and when we select a particular type trans only amounts pertaining to that should be used.

 

 

@Anonymous , if your formula is correct then just remove that from the filter and add to the slicer. As long as tables are connected it should filter

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.