Forum Discussion
Combing Tables in PowerBI
- 2 years ago
Hi! You're going to want to set your model up as a star schema so that you have fact and dimension tables. In this way you can have your actuals table and your budget table in as facts, and a date table that is the dimension. It would be joined to each fact table and that allows you to utilize the facts together in a visual through the join to the dimension (i.e. join facts with dimension, not fact to fact). You'll also need a dimension table for Center-Account which would also join to both facts. Then, in the visual you would pull in Center-Account from your dimension table, you month from a date table, and the actual and budget would be measures based on the fact tables. Here are two blogs posts I have about star schema and a great table I love: http://powerbiwithme.com/2023/07/30/the-star-schema-edition/ and http://powerbiwithme.com/2023/08/01/the-custom-date-table-edition/
- 2 years ago
for your budgeted table , go to power query and unpivot the table
this way you will have the month on the rows and per each row th budget ,
now you can link your dimdate table ( assuming you have one. if not, i recommened that you create one ) ,
to both tables.
and then you just need to drag and drop the columns from the tables to the visual :
dates from dimdate,actual spend from the first table , and budget amount from the budget_amount_table .
scorrera let me know if this works for you .
If my answer helped sort things out for you, i would appreciate a thumbs up 👍 and mark it as the solution ✅
It makes a difference and might help someone else too. Thanks for spreading the good vibes! 🤠
Hi! You're going to want to set your model up as a star schema so that you have fact and dimension tables. In this way you can have your actuals table and your budget table in as facts, and a date table that is the dimension. It would be joined to each fact table and that allows you to utilize the facts together in a visual through the join to the dimension (i.e. join facts with dimension, not fact to fact). You'll also need a dimension table for Center-Account which would also join to both facts. Then, in the visual you would pull in Center-Account from your dimension table, you month from a date table, and the actual and budget would be measures based on the fact tables. Here are two blogs posts I have about star schema and a great table I love: http://powerbiwithme.com/2023/07/30/the-star-schema-edition/ and http://powerbiwithme.com/2023/08/01/the-custom-date-table-edition/
- scorrera2 years agoRegular Visitor
Thank you for your repsonse. I think it has moved me forward but I'm still not there. This is what I have currently:
And it gives me these results:
FYI I did unpivot the data in the budget table so it looks like this:
- scorrera2 years agoRegular Visitor
Actually I think I was able to do it by setting the attribute column from unpivoting the months to a date format.
- Anonymous2 years agoNot applicable
Hi scorrera ,
Whether your problem has been resolved? If yes, could you please mark the helpful post as Answered? It will help the others in the community find the solution easily if they face the same problem as yours. Thank you.
Otherwise, could you please provide some sample data(exclude sensitive data) and explain your current situation? It would be helpful to get the solution. Thank you.
Best Regards