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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
f1254lipm
Frequent Visitor

Dynamic Column headers

Hi, I have the requirement for dynamic column names - the names of columns need to change based on certain conditions. I have tried to achieve this by implementing the technique described here: https://goodly.co.in/dynamic-column-names-power-query/

I have created a view in db with the column names, imported it (in import mode) and applied the transformations described above. The table where this dynamic change is supposed to happen is in direct query and all my other tables in the model are in dual mode. The report that uses this table contains a matrix and card visual.

The problem:

It works like it's supposed to in PBI desktop, but after I publish it, the visuals say Couldn't load data for this visual. 

Is there a way to fix this or achieve similar results with an alternative approach?

Many Thanks,
Filip

1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

Dynamic column names in Power Query are poison to the meta data tracker in the Power BI service.  They will cause all of your refreshes to fail unless you continuously update the app.

 

Instead,  create custom matrix visuals where you use either field parameters or measures as columns.

View solution in original post

3 REPLIES 3
ajinkyacgaikwad
Advocate I
Advocate I

Hi I faced the same issue
I have created a video for same 
Please let me know if it helps
Dynamic Column names in table visual : https://youtu.be/nAypPLYbeb4?si=3d_u_uRcPZBtbeB6

lbendlin
Super User
Super User

Dynamic column names in Power Query are poison to the meta data tracker in the Power BI service.  They will cause all of your refreshes to fail unless you continuously update the app.

 

Instead,  create custom matrix visuals where you use either field parameters or measures as columns.

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.