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
txpower
Regular Visitor

Income Statement Matrix

Hello, I am having issues building an income statement using the Matrix table. I have provided sample data below and an end-goal picture. I am trying to achieve the below:

 

1) TOTAL REVENUE as a sepereate line, then TOTAL DIRECT COSTS as another line (the sum of wage, materials, equipment).

2) CONTRIBUTION MARGIN, CM %, etc on seperate total lines.

3) I would like to sort Wages first, Materials Second, Equipment third.

 

 

Trying to achieve this look:

image1.png

 

Sample data:

DateAmountOBJ Account
Jan-201804.68Revenue
Jan-20243.3Revenue
Jan-20-1149.36Revenue
Jan-200Revenue
Jan-20-1604.1Revenue
Jan-20-264.98Revenue
Jan-20-1804.68Revenue
Jan-201149.36Revenue
Jan-200Revenue
Jan-201.3Revenue
Feb-20160.8Revenue
Feb-20160.8Revenue
Feb-20160.8Revenue
Feb-2044160.8Revenue
Feb-20160.8Revenue
Feb-20160.8Revenue
Feb-20200Revenue
Feb-20200Revenue
Feb-20200Revenue
Mar-20132.5Revenue
Mar-20132.5Revenue
Mar-20170Revenue
Mar-20170Revenue
Mar-20444436Revenue
Mar-20200Revenue
Mar-20200Revenue
Mar-20200Revenue
Mar-2070Revenue
Mar-2070Revenue
Mar-2060Revenue
Jan-2044475Wages
Jan-2063670Wages
Jan-2014803Wages
Feb-201154Wages
Feb-202133Wages
Feb-2026248Wages
Mar-20945Wages
Mar-202000Wages
Mar-20945Wages
Jan-2041Materials
Jan-202879Materials
Jan-203599Materials
Feb-205687Materials
Mar-202807Materials
Mar-202448Materials
Jan-20642Equipment
Jan-2045.47Equipment
Feb-2094.06Equipment
Mar-20219.08Equipment
Mar-2092.01Equipment
3 REPLIES 3
amitchandak
Super User
Super User

@txpower , You need to create sort column and then use it. example

 

A new column in the table

Switch( True(),

[OBJ Account] ="Wages" ,1,

[OBJ Account] ="Material" ,2,

//// Keep on adding

)

 

Mark it as the sort column

Refer steps :https://docs.microsoft.com/en-us/power-bi/desktop-sort-by-column

 

Sort Month Year.png

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, I am not following. Do you have an example work you can attach? 

Greg_Deckler
Community Champion
Community Champion

@txpower - You will need to implement a Sort By column using an if then else statement in Power Query and then sort your column by this sorting column.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

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 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.

Top Solution Authors