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
Syndicate_Admin
Administrator
Administrator

Power BI. Ask how to group data from a sales statistic by month,

First of all, thank you for your attention and the effort and time you dedicate to the layman.
I have a table called "Estarti" (this is an article statistic), it has the following fields: IdArticu, EndOfMonth, Units, Movement.
MonthEnd is a DD/MM/YYYY date field, IdArticu is text and the others are numeric integers.
These are the units sold per month of each of the different items we work with. "Movement" has a value of 0 if for a month there have been no units sold or 0 and a 1 if the month has had "units" sold other than 0.
I would like to be able to get a list of the items that have had movement in each and every one of the last 12 months, excluding the current month (the table is already filtered and only has those months). That is, the sum of the "movement" column has to be 12 for each "IdArticu". If it doesn't add up to 12, it's because it hasn't had units sold for a month.
Once I have obtained that list I would like to be able to filter it into, for example, those IdArticu whose units sold in each and every one of the last 12 full months has been at least 100 units, then it has been at least 50 units (excluding the previous 100), then at least 30 units, excluding the previous 50 and 100.
I've managed to do it in power query, but it's very laborious for me. Could you help me?

1 REPLY 1
Ritaf1983
Super User
Super User

Hi @Syndicate_Admin 

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.

https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523

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.