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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
harryli
Helper II
Helper II

How to transform the display table

harryli_0-1653972464025.pngharryli_1-1653972476554.png

As you may see from the above figures, the question is I would like to transform the table to be the following:

Total Bed 465

OC           89

FR            236

NOP        140

 

Thanks.

 

2 ACCEPTED SOLUTIONS
johncolley
Solution Sage
Solution Sage

Hi @harryli ,

 

You can accomplish this with a disconnected (no relationships to other tables) table that holds the values of the measures you want to display. The order column allows you to set a custom order.

johncolley_0-1654054462647.png

Then use a switch statement to display the correct value.

 

displaycolumn = 
var selection = SELECTEDVALUE('Measures (2)'[Measure])
RETURN
SWITCH(
TRUE(),
Selection = "Total Bed", [Total Bed],
Selection = "OC", [OC],
Selection = "FR", [FR],
Selection = "NOP", [NOP])

Then create a table with the Measure column from the disconnected table and the displaycolumn measure.

johncolley_1-1654054549855.png

I hope this solves your question - if it does please mark it as a solution!

View solution in original post

Hi @harryli ,

 

No, to follow the solution that Signore_Ands provided you just need to change your table to a matrix in the visualisation pane. Then the "Options" will be available to you.

 

johncolley_0-1654489442882.png

 

View solution in original post

8 REPLIES 8
v-jingzhang
Community Support
Community Support

Hi @harryli 

 

Have you tried the solutions provided by other two users? They should work well. For the second solution with Switch values to rows option, it is available in Matrix visual rather than Table visual.

 

Best Regards,
Community Support Team _ Jing

Signore_Ands
Advocate II
Advocate II

Hi @harryli - is it not a case of changing the setting "switch values to rows"?

 

Signore_Ands_1-1654077781716.png

That may do the trick.

harryli_0-1654487939858.png

harryli_1-1654487964815.png

Thanks for your message, but I cannot find the "Options" in the dashboard.

 

Hi @harryli ,

 

That option is only available when using the matrix visual, not the table visual as you currently are using.

Hi @johncolley ,

That means I need to build the matrix table* to store each of the values I want to display. Or are there any methods to transform the table visual?

 

*matrix table like the following figure

harryli_2-1654488538206.png

 

Thanks a lot.

 

 

Hi @harryli ,

 

No, to follow the solution that Signore_Ands provided you just need to change your table to a matrix in the visualisation pane. Then the "Options" will be available to you.

 

johncolley_0-1654489442882.png

 

Thanks, and it works.

johncolley
Solution Sage
Solution Sage

Hi @harryli ,

 

You can accomplish this with a disconnected (no relationships to other tables) table that holds the values of the measures you want to display. The order column allows you to set a custom order.

johncolley_0-1654054462647.png

Then use a switch statement to display the correct value.

 

displaycolumn = 
var selection = SELECTEDVALUE('Measures (2)'[Measure])
RETURN
SWITCH(
TRUE(),
Selection = "Total Bed", [Total Bed],
Selection = "OC", [OC],
Selection = "FR", [FR],
Selection = "NOP", [NOP])

Then create a table with the Measure column from the disconnected table and the displaycolumn measure.

johncolley_1-1654054549855.png

I hope this solves your question - if it does please mark it as a solution!

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.