Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
I am trying to complete a measure where I can look at the units sold, but the time period is a bit different.
I would like to see the units sold after the first 6 months after launch and then see the next 12 months.
So for example, if my product launched 6/1/2018 the measure must ignore the first six months so I want to start summing units beginning Dec 2018 and then continue for next 12 months.
Tried to work up this measure by myself. See below.
Any advise I would appreciate it.
Thanks
Solved! Go to Solution.
Of course after posting on the forum I tried another idea that worked for me.
First I added a column to my dataset that took the ship_date_month and added 6 months to it. Then this measure worked for me.
Of course after posting on the forum I tried another idea that worked for me.
First I added a column to my dataset that took the ship_date_month and added 6 months to it. Then this measure worked for me.
Would be willing to take a look at it but would really appreciate some sample data or the PBIX you are working with.
Thanks for the reply, for now I'm going to go with the model as is. I tested a number of products in excel and everything seems to be working as expected.
Thank you for the offer to help.
Any time!
I think you have nailed it. The only two difference I can think of one is We could have done +6 months here in this formula. Now + startof month can be replaced with min or max .
Other one using date calendar as we should prefer using date calendar for time intelligence
Rolling 11 till after 6 month = CALCULATE(sum('BI CompOrders_Trend_Tbl'[order_quantity]),DATESINPERIOD('Date'[Date],startOFMONTH(dateadd(Sales[Sales Date],6,month)),11,MONTH))
To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :
https://radacad.com/creating-calendar-table-in-power-bi-using-dax-functions
https://www.archerpoint.com/blog/Posts/creating-date-table-power-bi
https://www.sqlbi.com/articles/creating-a-simple-date-table-in-dax/
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
92 | |
86 | |
85 | |
67 | |
49 |
User | Count |
---|---|
140 | |
113 | |
104 | |
64 | |
60 |