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
Farooqh
New Member

Percentage monthly wise for Matrix tabled Data

HI,

 

I have a measure which does calculation to get Net sales values based on the slicer selection.

 

Net sales Monthly wise total measure: 

MSR_MON_FCST_NET_SALES =
VAR SELECTED_DIV = ALLSELECTED(DIVISION[Division])
VAR SELECTED_BU = ALLSELECTED(BUSINESS_UNIT[Business_unit])
VAR SELECTED_SEG = ALLSELECTED(SEGMENT[Segment])
RETURN
CALCULATE(SUM(INCOME_STATEMENT_DATA[MONTHLY_CURRENT_FORECAST]),FILTER(
INCOME_STATEMENT_DATA,INCOME_STATEMENT_DATA[DIVISION] IN SELECTED_DIV && INCOME_STATEMENT_DATA[Segment] IN SELECTED_SEG && INCOME_STATEMENT_DATA[Order_Line_items]= 2 && INCOME_STATEMENT_DATA[Business_unit] IN SELECTED_BU && INCOME_STATEMENT_DATA[FIN_GROUP] = INCOME_STATEMENT_DATA[FIN_GROUP] && INCOME_STATEMENT_DATA[BUID] = INCOME_STATEMENT_DATA[BUID] && INCOME_STATEMENT_DATA[MONTH] = INCOME_STATEMENT_DATA[MONTH]))

 

This measure will give me the net sales value, and i got to divide this with other line items value.

For example:  Gross sales, ADITA, and etc.

 

So, I have this measure 
MSR_MON_%_FCST_NET_SALES = DIVIDE(SUM((INCOME_STATEMENT_DATA[MONTHLY_CURRENT_FORECAST])),CALCULATE([MSR_MON_FCST_NET_SALES],ALLSELECTED()))

 

Now what I want is, Matrix visualization. When I put this measure in the values and Line times in the rows and Month in columns, the total is getting distributed, 

But what i want is, total should not be distributed and it should strict with month wise.

Farooqh_0-1592989918674.png

 

Net sales should always be 100% and this net sales measure should divide with other and give percentage monthly wise.

 

Any suggesstions, please?

 

 

2 REPLIES 2
v-deddai1-msft
Community Support
Community Support

Hi @Farooqh ,

 

Would you please inform us more detailed information( your  data(by OneDrive for Business)) if possible? Then we will help you more correctly. 

 

The filter condition in your first measure:  "&& INCOME_STATEMENT_DATA[FIN_GROUP] = INCOME_STATEMENT_DATA[FIN_GROUP] && INCOME_STATEMENT_DATA[BUID] = INCOME_STATEMENT_DATA[BUID] && INCOME_STATEMENT_DATA[MONTH] = INCOME_STATEMENT_DATA[MONTH])"  would run into wrong value. But that's just my guess until I have your sample data.

 

Please do mask sensitive data before uploading.

 

Thanks for your understanding and support.

 

Best Regards,

Dedmon Dai

amitchandak
Super User
Super User

@Farooqh , did not get it completely but with the help of infiltered or isinscope you should able to change measure for Sub total and grand total

https://www.kasperonbi.com/use-isinscope-to-get-the-right-hierarchy-level-in-dax/

https://powerpivotpro.com/2013/03/hasonevalue-vs-isfiltered-vs-hasonefilter/

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.