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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Anonymous
Not applicable

Building a Specific Matrix Table

Hi, I have two tables of data that I need to analyze and show budget vs actuals:

 

NameMonthTransaction Amount
Bill GatesJanuary65
Bill GatesJanuary88
Bill GatesFebruary19
Bill GatesFebruary43
Bill GatesFebruary69
Bill GatesFebruary78
Bill GatesMarch64
Bill GatesMarch12
Bill GatesMarch39
Bill GatesMarch51
Tim CookJanuary47
Tim CookJanuary69
Tim CookFebruary21
Tim CookFebruary85
Tim CookFebruary13
Tim CookFebruary27
Tim CookMarch68
Tim CookMarch13
Tim CookMarch29
Tim CookMarch98

 

NameBudget
Bill Gates600
Tim Cook500

 

I have been able to make the matrix look like this:

 

NameTransaction SumBudgetBudget Remaining
Bill Gates52860072
Tim Cook47050030

 

However, I am trying to add the months into the drill down to look like this: Notice how the budget remaining includes a rolling total and the budget is divided into the months:

 

NameTransaction SumBudgetBudget Remaining
Bill Gates   
January153200447
February209200238
March16620072
Total52860072

 

Honestly, I would really prefer the table to look like this below, but I do not think it is possible. I would love for someone to prove me wrong:

 

NameJanuaryFebruaryMarchTotal Transaction AmountBudgetBudget Remaining
Bill Gates15320916652860072
Tim Cook13712520847050030
1 ACCEPTED SOLUTION
MFelix
Super User
Super User

Hi @Anonymous ,

 

Create the following measures:

Actuals Value = SUM(Actuals[Transaction Amount])

Budget Total = if (HASONEVALUE(Actuals[Month]);BLANK();SUM(Budget[Budget]))

Remaining = IF([Budget Total] = BLANK();BLANK();[Budget Total] - Budget[Actuals Value])

Then add the values on a matrix table:

  • Rows: Budget[Name]
  • Columns: [Actuals Month]
  • Values:
    • Actuals Value
    • Budget Value
    • Remaining

This will give the table below:

months.png

Has you can see the Budget Total and reaming columns are blank on the values just resize those columns until they are not visible and be sure to turn off wrap text on  the options:

months_1.png

The months are not in the correct order because is just a mockup. See attach PBIX file.

 

Regards,

MFelix


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



View solution in original post

2 REPLIES 2
MFelix
Super User
Super User

Hi @Anonymous ,

 

Create the following measures:

Actuals Value = SUM(Actuals[Transaction Amount])

Budget Total = if (HASONEVALUE(Actuals[Month]);BLANK();SUM(Budget[Budget]))

Remaining = IF([Budget Total] = BLANK();BLANK();[Budget Total] - Budget[Actuals Value])

Then add the values on a matrix table:

  • Rows: Budget[Name]
  • Columns: [Actuals Month]
  • Values:
    • Actuals Value
    • Budget Value
    • Remaining

This will give the table below:

months.png

Has you can see the Budget Total and reaming columns are blank on the values just resize those columns until they are not visible and be sure to turn off wrap text on  the options:

months_1.png

The months are not in the correct order because is just a mockup. See attach PBIX file.

 

Regards,

MFelix


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Anonymous
Not applicable

Thank you very much @MFelix. I was really overthinking it 🙂

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

AugPowerBI_Carousel

Power BI Monthly Update - August 2024

Check out the August 2024 Power BI update to learn about new features.

August Carousel

Fabric Community Update - August 2024

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