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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
cgallegos
Regular Visitor

Dynamic Column Headings - Dates Over Time

Hi - I am wanting to have column headings that change as my dashboard is refreshed or updated.

 

For example,  I'd like the below "current week" heading to say "Jan 14-20" as the values in that column are calculated for that date range. Is there a way to do this?

 

Thank you,

 

cgallegos_0-1643397732798.png

 

1 ACCEPTED SOLUTION

I initially implemented this as a DAX calculated column but then realized this would not work as it doesn't sort the result correctly. I reverted back to the standard method of supplying an external calendar table instead.  See attached for both options.

View solution in original post

9 REPLIES 9
lbendlin
Super User
Super User

If by "dynamic"  you mean "recalculated during every import mode dataset refresh"  then yes.  Otherwise please provide more details, some sample data would be nice too.

Essentially, I'd like to see week over week # of Hired Employees. The weeks runFriday-Thursday, though. 
For example, if my raw data looks like something like this:

 

HiresRegionEffective Date of HireDashboard Refresh Date
1Consumer Ret1/14/20221/31/2022
1Consumer Ret1/14/20221/31/2022
1Consumer Ret1/14/20221/31/2022
1Consumer Ret1/14/20221/31/2022
1Consumer Ret1/14/20221/31/2022
1Consumer Ret1/20/20221/31/2022
1Consumer Ret1/21/20221/31/2022
1Consumer Ret1/21/20221/31/2022
1Consumer Ret1/27/20221/31/2022

 

And I'd like it summarized like this

 

 Hires
RegionJan 14-20Jan 21-27YTD
Consumer Ret639

 

 

What would be the expected column header for the next week?  "Jan 28-Feb 3" ?  You may be running out of screen real estate fast.

Hi,

Yes, next column would be Jan 28-Feb 3. I am only planning to show the last 4 weeks.

PLease add some more sample data so it covers that whole period.

Let me know if you need any additional data.

I initially implemented this as a DAX calculated column but then realized this would not work as it doesn't sort the result correctly. I reverted back to the standard method of supplying an external calendar table instead.  See attached for both options.

Thank you!!

Raw Data: 

 

HiresRegionEffective Date of Hire
1Consumer Ret1/14/2022
1Consumer Ret1/14/2022
1Consumer Ret1/14/2022
1Consumer Ret1/14/2022
1Consumer Ret1/14/2022
1Consumer Ret1/20/2022
1Consumer Ret1/21/2022
1Consumer Ret1/21/2022
1Consumer Ret1/27/2022
1Consumer Ret1/28/2022
1Consumer Ret1/28/2022
1Consumer Ret2/3/2022
1Consumer Ret2/3/2022
1Consumer Ret2/3/2022
1Consumer Ret2/4/2022
1Consumer Ret2/4/2022
1Consumer Ret2/10/2022
1Consumer Ret2/10/2022

 

Week Over Week - What I'd Like to Get to

RegionJan 14-20Jan 21-27Jan 28-Feb 3Feb 4 - Feb 10YTD 
Consumer Ret635418

 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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