cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
PBI_newuser
Post Prodigy
Post Prodigy

how to calculate total cumulative sales in descending order

Hi, how to calculate the cumulative sales for total selected months in descending order by Country, Company and SKU? Below is the sample data.

https://drive.google.com/file/d/1QSxBcandDoIpdo4aA4uAkrIfpC0YNwSY/view?usp=sharing

 

For example, I select Jan to Dec 2023, the cumulative sales should calculate the total sales in descending order.

After calcuting the cumulative sales, I need to categorize the SKU in ABC category. The logic is as below:

  • A: if cumulative % is <= 80%
  • B: if cumulative % is <=90%
  • C: if cumulative % is <=95%
  • D : if cumulative % is <=100%
  • else "Exited"

Expected output (in red):

PBI_newuser_0-1687828406212.png

 

1 ACCEPTED SOLUTION
Ashish_Mathur
Super User
Super User

Hi,

Please find attached my solution file.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

5 REPLIES 5
Ashish_Mathur
Super User
Super User

Hi,

Please find attached my solution file.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Hi @Ashish_Mathur , thanks for the solution! It works! 🙂

You are welcome.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
amitchandak
Super User
Super User

@PBI_newuser , Refer if this can help

Power BI ABC Analysis using Window function, Dynamic Segmentation: https://youtu.be/A8mQND2xSR4

Hi @amitchandak, I tried this solution but got below error.

PBI_newuser_0-1687918109335.png

 

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors