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
AlanP514
Helper V
Helper V

Dynamic Title Based on versions

Hai All, I need your support on this 
Scenario: I  working on a sales report,

AlanP514_0-1654670645449.png

In the Version (top) you can see the latest version and the bottom red line(previous version)
I want to create a  dynamic title based on these
The output should be dynamic For eg: The latest version is  V6-June-2021 And the Previous Is V5-May-2021
So I want to set a dynamic title based on these versions 
Output = Sales Forecast Trend by Volume -[V6-June-2021 vs V5-May-2021]
If the user sends a new version next month(V7-July-2021) so the output should be [V7-June-2021 vs V6-June-2021]
Thanks 
Alan

Note: In this table has a column called forecast version 

AlanP514_1-1654670978657.png

So every month if new version appended in this column will reflect

2 REPLIES 2
AlanP514
Helper V
Helper V

Thanks for the solution, but could you please mention the  Dax to create a dynamic title based on a measure which you created now 
output 
Sales Forecast Trend by Volume -[V6-June-2021 vs V5-May-2021]

amitchandak
Super User
Super User

@AlanP514 ,

 

Create a new column in DAX (on in power query)

 

Date = datevalue(right([version], len([version]-1) )

 

Now create a rank

Rank  = rankx(Table, [Date],,desc, dense)

 

now

flag for latest

if([Rank] =1 1, "Latest", [Rank])

 

these column can be used Rank can also used to find by adding +1

 

refer examples, I have used -1 as I have desc rank (Custom Period)

 

DATESMTD, DATESQTD, DATESYTD, Week On Week, Week Till Date, Custom Period on Period,
Custom Period till date: https://youtu.be/aU2aKbnHuWs&t=145s

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.