Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
AgoZ_KH
Resolver I
Resolver I

How to change name labels dinamically in a pBI report table

Hi to all my best community!! 

my problem to day is how to rename dinamically the labels of a table in a power BI report.

I have some data and calculation by week. My reports present the data for actual week -4; -3; -2 and -1 in other words groups data by a mounth

So the colum order is by example:

IdName | City | Number | week 36 | week 37 | week 38 | week 39 |

the week 39; 38; 37 and 36 are respectvely the week -1; -2 and so on

Every new week my problem is that a new column must to be rapresented. with the new week data

Data of my columns are parametrics so they are re-calculated for every week starting from the current week. My problem is how to change columns label applicated to every measure or how to made parametrics the labels so that when the week became xx+1 the label for measure week-1 became from label xx to label xx+1 (i.e. w37 became w38).

Woukd appreciate any help.

Greetings to all
Ago

3 REPLIES 3
Icey
Community Support
Community Support

Hi @AgoZ_KH ,

 

To my knowledge, I'm afraid that Power BI cannot meet your requirements currently.

 

 

Best Regards,

Icey

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

amitchandak
Super User
Super User

@AgoZ_KH , You can create a column like this and keep that in filter

 

new column =
var _week = weeknum(today(),2) //use 1 for sunday week
return
Week weeknum([Date],2) -_week

 

If needed you can use week rank in place of week num, that will work across the year

Week Rank = RANKX(all('Date'),'Date'[Week Start date],,ASC,Dense) // on Year Week

 

Refer my blog for that

https://medium.com/@amitchandak.1978/power-bi-wtd-questions-time-intelligence-4-5-98c30fab69d3
https://community.powerbi.com/t5/Community-Blog/Week-Is-Not-So-Weak-WTD-Last-WTD-and-This-Week-vs-La...

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hi @amitchandak  thanks a lot for suggestions!

 

I had successfully managed week time for my specific problem, not in the very intelligent way you made with WDT time intelligence suggested in your blogs. I keep your suggestions on the matter live for future. But into specific that seem not helpfull for me. I Try to explain better my trouble.

 

I have a measure that calculate average by the last fours weeks. So they actualize the calculation everytime a week change.

My problem is to change LABEL Columns dinamically (not the calculation) when week change number.

Suppose my measure have the name:

week 1 | week 2 | week 3 | week 4 |

I put this measure in a report table and then I change manually names so the table in the report has headers like:
w 39 | w 38 | w 37 | w 36 |

Next week the measure "week 1" calculate dinamically average for the 40th week and so on.

So my table must became
w 40 | w 39 | w 38 | w 37 |
and in the relative colums measure remain
week 1 | week 2 | week 3 | week 4 |

How to rename headers without recurring to a manual change, but make this automatically??

 

Thanks in advance for every suggestions!

Ago

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors