Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hi,
I think I have made a modelling mistake that on a single sta schema doesnt cause issues. Its because Im now pulling multiple data sets together and those data sets hold a star schema each.
So I have the following:
they are at different levels of granularity and the ID is in the fact table so that the actual Work table can be aggregated on just WorkType so its a very small dim table
Using each seperately is fine but now I have hit this pulling in both data sets. I bring them together like this:
And the report Is made up like this
So if you were to drag the ID Key froM fact table B into trips table you can see that its completely disconnected. So putting the ID into the fact table doesnt work when you bring together more than one fact table. I have a few options
1. Add ID into Work making that Dim table a lot bigger and it will be a 1 to 1 join onto the fact table
2. Create a seperate dim just for the ID (But it seems like an odd thing to da)
Is there another way of resolving this so i can leave the IDs in the Fact table. Whats the best practice I should be using here? Any help would be appreciated
Solved! Go to Solution.
No I cant share this pbix file.
And its all sorted. I created the dimension with the ID. removed the ID from the fact table. And I kept the higher dim with just the type in it for the star schemas at the higher level of granularity.
Took a while but it was worth it and everything is working well now
Looks like this has been out here for a couple years but was wondering if the issue was actually one of not considering the purpose of the fact table.
Why not simply have a FactCost fact table containing all "Costs" regardless of the cost type with columns WorkKey, CostKey, and Cost. A dimension DimWork with columns WorkType, WorkKey, and ID. A dimension DimCost with columns CostTypeKey, CostKey, and CostDescr. A dimension DimCostType with columns CostKeyType and CostTypeDescr.
This would allow for any new cost types to be added without the need for additional Fact tables. Also allow simple aggregations to provide total costs, measures filtered by Cost Type for segmentation, and a much easier time doing calculations like cost or cost type as a percentage of total cost.
Thats helped me figure out the plan. Create another dimension at the lowest level of granularity with the ID, And move the ID out of the fact table. Its a bit of work but it needs to be done.
Hi Debbie are you able to share a pbix file and an idea of the desired output.
What you're describing is generally called a degenerate dimension by Kimball (https://www.kimballgroup.com/data-warehouse-business-intelligence-resources/kimball-techniques/dimen...).
Normally you would leave it on the fact table but because you're looking to report at that level across two fact tables I think your best course of action it to pull it out as a dimension with just those id's in as you suggest. Anything else just leads to complex dax to pass the filters.
No I cant share this pbix file.
And its all sorted. I created the dimension with the ID. removed the ID from the fact table. And I kept the higher dim with just the type in it for the star schemas at the higher level of granularity.
Took a while but it was worth it and everything is working well now
@DebbieE Option 2, a dimension table for ID and all the common columns related to ID will go into this table and it will have relationship with both the fact tables.
I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop shop for Power BI-related projects/training/consultancy.
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
147 | |
85 | |
66 | |
52 | |
46 |
User | Count |
---|---|
215 | |
90 | |
83 | |
66 | |
58 |