LAST N MONTHS WITH SELECTED MEASURES IN POWER BI | DYNAMICALLY SELECT PAST N MONTHS WITH ANY MEASURE

แชร์
ฝัง
  • เผยแพร่เมื่อ 15 ธ.ค. 2024

ความคิดเห็น • 64

  • @MorySavané-u9t
    @MorySavané-u9t 2 หลายเดือนก่อน

    Thanks soooooo much! I was blocked when working on very important project for the company!
    Good Job!

  • @pabloramirez7300
    @pabloramirez7300 ปีที่แล้ว

    i loved it, it helped me a lot, thanks, I was just blocked and this video put me on the rail again , thanks

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว +1

      Glad it helped! Thanks for watching.

  • @KMF7955
    @KMF7955 ปีที่แล้ว +1

    Hi, this video has really been helpful. Thank you so much! If I changed this visual from a column chart to a matrix how would I remove all the months that are appearing with zero values?

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      Glad to know it is so useful to you. you can do so by replacing the 0 values with blank inside your DAX expressions. depending on the visual's need.

    • @KMF7955
      @KMF7955 ปีที่แล้ว

      @@PowerBIHelpline That did the trick! Thank you so much.

    • @usamaqadeer
      @usamaqadeer ปีที่แล้ว

      Hi very useful video, I have implemented using your logic, my question is how can we replicate this with the week such as last n weeks in the period, and your dax measure has interval as month but it doesn't support week

  • @pranayvamshi
    @pranayvamshi 9 หลายเดือนก่อน

    This video helped me a lot, Thank you.

  • @feng3625
    @feng3625 ปีที่แล้ว +1

    All are great; please, if you could help me. I like to have the last 3 previous months (based on the current day, but without the current month) and no slicer.

    • @feng3625
      @feng3625 ปีที่แล้ว

      The last 3 previous, like now, is Apr. 2023. I want Jan 2023, Feb 2023, and Mar 2023 sales; there is no slicer. Could you help?

  • @govindsajeev8754
    @govindsajeev8754 28 วันที่ผ่านมา

    How can I do the conditional formatting to give green color alone for the month with highest no of sales?

    • @PowerBIHelpline
      @PowerBIHelpline  25 วันที่ผ่านมา

      Thanks for watching. We have posted videos about conditional highlights including the highest/lowest values please checkout the playlist.

  • @anindependentms8504
    @anindependentms8504 ปีที่แล้ว

    Hi! Thank you for this video. It’s very easy to follow. But somehow, whenever I select a Month from the slicer, the chart will show zero values for the month(s) prior to that Month selected in the slicer. I can’t understand why. Can you help out? Thanks!

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      Glad to know it is helpful. If you follow along, make sure you are not missing any step.also check out your Power BI Data model for any unwanted automatic relationships. if everything is right it should work same way as it works in the demo.

  • @Robert-qn6tt
    @Robert-qn6tt ปีที่แล้ว

    Perfect example, very helpful! Similar doubt here. It works well but I only see those periods with data (bars for periods with no data are hided). If i want to see those hided bars i can show blank data (for X axis, period) but then i see all calendar periods, not only the last n.
    Any idea to see only the last N even if they do not have data?
    Thanks

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      Glad it was helpful!
      For this you need to add additional validation in your expression, which will also check if COUNTROWS() in that particular scenario is blank or not including the date ranges to fall within previous N months.

    • @Robert-qn6tt
      @Robert-qn6tt ปีที่แล้ว

      Thanks! Could you please provide a simple example of this validation? Thanks a lot!@@PowerBIHelpline

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      You can send an email by mentioning the detailed requirement, with some sample/dummy dataset.

    • @Robert-qn6tt
      @Robert-qn6tt ปีที่แล้ว

      The data you have in the video is enough. Simply erase one month sales data from the datasource and select a period that includes that month. Cause is blank, It will not appear in the axis, neither in bars, of course. The visual effect is that you have selected n-1 periods. If you want to see it you can show blank data for the x axis but then you see all the periods of the secondary dates, not only the selected ones.
      One solution can be put 0 instead of blank but i've not realized how to do it only for the sales for the selected period. When i try it, all periods, even if they are not in the selected period, with no data appears as 0, so they also appears in the x axis.
      Thanks so much for you help

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      @@Robert-qn6tt
      Store the final result in a variable called _result and then return with below expression-
      IF(
      SELECTEDVALUE('new Dim Date'[Year-Month]) IN
      CALCULATETABLE(
      VALUES('new Dim Date'[Year-Month]),
      'new Dim Date'[Date] in _Periodshift
      ) && _result = BLANK(),
      0, _result
      )

  • @dabarapraise8287
    @dabarapraise8287 9 หลายเดือนก่อน

    pls did you create the dimdate table from the sales table then duplicated it?

    • @PowerBIHelpline
      @PowerBIHelpline  9 หลายเดือนก่อน

      Yes, You can create a date table in Power query as well

  • @paulinapru3224
    @paulinapru3224 ปีที่แล้ว

    Thank you!!! This video really helped me. Instead of the last 6 months could it select all previous dates?

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      Glad to know it was helpful to you. This is dynamic Last N month not last 6 months. and yes, with little changes you can have all previous day as well.

  • @julie_chen
    @julie_chen 4 หลายเดือนก่อน

    Thank you! 3x ❤❤❤❤😊😊😊😊

  • @rafiah95
    @rafiah95 ปีที่แล้ว

    Hi, thank you for the video. May I know how to have the sequence of the Year-Month in the bar chart accordingly?

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว +1

      To have such sequence, you can either sort the year month column by an additional sort helper column of year month with integer value e.g. 202310 for Oct 2023. Or you can duplicate the date column and the change the format to Year month

  • @AkhilDuvvuru
    @AkhilDuvvuru 11 หลายเดือนก่อน

    Hi @PowerBIHelpline, Thanks for this video. Really helps! Can you please help me with on how to get last 3/6/12 closed months including the current month to date? (Eg: If we are on 26th Dec and if I want last 3 months then I want to show Sep, Oct, Nov all full months + Dec till 26th)

    • @PowerBIHelpline
      @PowerBIHelpline  11 หลายเดือนก่อน

      Glad to know it is helpful to you.
      I personally like such period comparison, and have posted multiple videos on these topic. I think you should check this video "CUSTOM PERIOD SLICER IN POWER BI"

  • @AITrendsExpert-in9qj
    @AITrendsExpert-in9qj หลายเดือนก่อน

    how can you also include a category slicer to this?

  • @Krafftc
    @Krafftc ปีที่แล้ว

    Are you able to show or explain how you could have this functionality work with a Prior year bar also?

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      I have posted a video, how to show previous year single column, and then followed by monthly columns for current year, and in last a single column for Budget. you can use the techniques from that video, along with this.

  • @dhananjaywalunj3652
    @dhananjaywalunj3652 6 หลายเดือนก่อน

    Hi, it's informative 👍. Can we do the same with the fiscal calendar as well?

  • @SaravananBpve
    @SaravananBpve 7 หลายเดือนก่อน

    what is the formula used in the Period Column

    • @PowerBIHelpline
      @PowerBIHelpline  7 หลายเดือนก่อน

      there are many ways to get this,
      1- Concat Year and month name column
      2- change the format of date column to yyyy- mmm

  • @yousefesfahanian2636
    @yousefesfahanian2636 5 หลายเดือนก่อน

    Why do you make the connection between two tables "one to many"? i guess it is wrong as we have only distinct values in both columns!

    • @PowerBIHelpline
      @PowerBIHelpline  5 หลายเดือนก่อน

      Yes, That doesn't matter in this case.

  • @anushaghiremath
    @anushaghiremath ปีที่แล้ว

    Hi, Thank you for this video. Have also tried doing the same I'm getting column total wrong for the last 4 months.

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      If it is only for the last 4 months, then you should checkout the expressions.

    • @anushaghiremath
      @anushaghiremath ปีที่แล้ว

      @@PowerBIHelpline Thanks for the reply. Have checked the expression and I'm using dynamic slicer to check -1% of moving or 5% of moving average.

  • @testprime4248
    @testprime4248 ปีที่แล้ว

    Thx, this is perfect.

  • @sachinbhalerao9651
    @sachinbhalerao9651 ปีที่แล้ว

    Hi I want to select last month data dyanamically in report how can I do

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      Recently i posted a video on this topic to select latest month dynamically in Power BI slicer. check that out.

  • @gabrielfrancisco8943
    @gabrielfrancisco8943 ปีที่แล้ว

    You are amazing

  • @naveenponugoti7344
    @naveenponugoti7344 2 ปีที่แล้ว +1

    Nice

  • @ramadhaninugraha9040
    @ramadhaninugraha9040 ปีที่แล้ว

    Hi interesting tutorial, love it! Could you provide the pbix file to download and let us see the detail?

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      Thanks for watching. To get the PBIX file, you can send an email by mentioning the video title as email subject.

  • @Gua10ify
    @Gua10ify ปีที่แล้ว

    How to count Average sales in last 6 months ?

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว +1

      If you want to have a rolling average. you can use DATESINPERIOD() DAX function

  • @thompham8903
    @thompham8903 ปีที่แล้ว

    Can you give me that file again? thank you

  • @vaibhavwankhede8691
    @vaibhavwankhede8691 ปีที่แล้ว

    I need PBIX file
    How to download it?

    • @PowerBIHelpline
      @PowerBIHelpline  ปีที่แล้ว

      Thanks for watching. To get the PBIX file, you can send an email by mentioning the video title as email subject.

  • @andrea2686
    @andrea2686 7 หลายเดือนก่อน

    i see that the months don't sorted well

    • @PowerBIHelpline
      @PowerBIHelpline  7 หลายเดือนก่อน

      You can apply a sort order. We have also posted a video for Past N or future N months based on selected measure, you can check it out. Sort order is also taken care in that.