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
nicocgn
New Member

Graph do not work with measures made with SWITCH function

Hello, I am creating a Financial Statement from zero in PBI where I have a "Profit and Loss" table with just the name of items (like Sales, Cost, earning...) and for each line item I have created a Measure for calculating the amount.

I can build a visualization "Table" where I can associate each line item to the relative measure thanks to an additional measure built with DAX function "Switch". However, the problem arise when I want to create a Line Bar chrart beacuse seems I cannot use the measue and the Profit and loss structure as I have done for the Table. Why is that? 

 

Maybe, should I create an additional Table on PBI composed by two column: one of the Profit and Loss Structure and the other one withe the measure created? How it can be done?

 

thank you

1 REPLY 1
amitchandak
Super User
Super User

@nicocgn , Not very clear. I have a couple videos and a blog on this topic

 

Power BI How to get the P&L formatting right: https://youtu.be/C9K8uVfthUU
Power BI How to get two columns format Profit and Loss Statement(P&L) right: https://youtu.be/WLg85yiMgHI

 

https://medium.com/microsoft-power-bi/power-bi-formatted-p-l-with-custom-sub-totals-and-blank-rows-e...

 

 

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

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.