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
thomsontam
Frequent Visitor

Dynamic month report with versus prior month

Hi,

 

I could like to get a report like the following layout 

CustomerDec-20Jan-21Feb-21VPM
A12109-1
B1011121
C8990

 

I am able to use a dynamic month measure to get individual month and VPM calculate but I only managed to present using the following layout :

 Dec-20 Jan-21 Feb-21 
CustomerSalesVPMSalesVPMSalesVPM
A12 10-29-1
B10 111121
C8 9190

 

 

May I ask are there anyway I can write a DAX that can shows a report like the first layout?

Thanks!

1 ACCEPTED SOLUTION
Jihwan_Kim
Super User
Super User

Hi, @thomsontam 

Please check the below picture and the sample pbix file's link down below.

I am not sure about how your whole data model looks like. But I want to suggest having an additional table for the new column that contains VPM. The measures are in the sample pbix file.

If it is OK with you, please share your sample pbix file, then I can try to come up with more relevant measures suggestions.

 

Picture3.png

 

https://www.dropbox.com/s/94nca2lwpklbxfz/Omar.pbix?dl=0 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM

 

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Go to My LinkedIn Page


View solution in original post

5 REPLIES 5
Jihwan_Kim
Super User
Super User

Hi, @thomsontam 

Please check the below picture and the sample pbix file's link down below.

I am not sure about how your whole data model looks like. But I want to suggest having an additional table for the new column that contains VPM. The measures are in the sample pbix file.

If it is OK with you, please share your sample pbix file, then I can try to come up with more relevant measures suggestions.

 

Picture3.png

 

https://www.dropbox.com/s/94nca2lwpklbxfz/Omar.pbix?dl=0 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM

 

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Go to My LinkedIn Page


Hi Kim,

 

Thanks for your reply, your output looks as same as what I am looking for, however, could you please reshare the file in DropBox? The file in dropbox looks difference then the picture shows above.

 

Thanks again!

 

Regards,

Thomson

Hi, @thomsontam 

Sorry, my mistake.

Please check the below link.

 

https://www.dropbox.com/s/9j1ycogucaeootu/thomson.pbix?dl=0 

 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Go to My LinkedIn Page


My data structure is very similar to yours, so I can adjust my table for it.

Only 1 thing I still try to do myself is the date range selection working on earlier period to last month. (any time up to April).  However, if I select From Dec 20 to Mar 21 then VPM not give the correct result.  
edit: I modify the DAX so I can get any 4 months period with the last one with VPM based on a Period selector.  Thanks for your help KIM, it really helps on my dashboard report!

 

Thanks for your help, I can use this method for my other monthly trend report which need the % of Grand total at the end! 

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.