Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for a $400 discount.
Register nowGet inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.
I really need some help with designing a star schema for a series of sequential 'business' process events.
I have the following clear dimensions:
date calendar,
children,
interventions types,
referral types,
referral action types
A child can have multiple interventions, each with a start and an end date.
A child can then have multiple referrals each with a start and end date
A child may then have multiple referral programmes each with a start and end date
Each programme can have multiple referral actions which are specific to the programme type.
Each of these processes is hierarchical i.e. a child cannot have a referral programme without first having a referral and a child cannot have a referral without having first had an intervention.
Ultimately, I need to be able to find all interventions ending in a given period and show all related referral, referral programmes and referral action data. Ideally I want to show all possible programme actions and whether or not a child that has a specific referral has completed these actions. I'm not worried about the dates as I will probably use power query to resolve this.
I am struggling to model this in a star schema. I assume that each of the processes is a FACT table. I know it is bad practice to link FACT tables. I have moved on to thinking it may work to have child referral programme actions as the main fact table and each of the earlier processes as dimensions i.e
Dim Interventions: intervention key, child, type, start, end date
Dim Referrals: Referral key (composite of Intervention key and referral type), intervention key, referral type, start, end date,
Dim Referral Programme: Referral Programme (composite of Referral key and referral intervention type), referral intervention key, referral intervention type, start, end date
FACT: Unique key, Child Key, date key, Referral key, referral programme key, Referral Action.
Would this work? Would I then relate to the other dimensions giving types to the FACT table or these dimensions?
The alternative approach would be to create each of the processes as a separate FACT and relate each to the appropriate dimensions and then build a dax measure to summarise all of the detail (not that I'm sure my dax is up to that!).
Are either of these viable? I have gone down a couple of rabbit holes already and found I couldn't quite filter my data correctly!
Solved! Go to Solution.
Hi @scoobymoo1 ,
Your scenario is quite complex due to the hierarchical nature of interventions, referrals, programs, and actions. Let's break it down and explore the best approach.
This is the approach you proposed—having one central fact table with each previous step as a dimension.
Fact_ReferralProgramActions (Granularity: One row per referral program action)
Dim_Children (Child-related data)
Dim_Calendar (Dates for analysis)
Dim_Interventions (InterventionKey, ChildKey, Type, Start, End)
Dim_Referrals (ReferralKey, InterventionKey, Type, Start, End)
Dim_ReferralPrograms (ReferralProgramKey, ReferralKey, Type, Start, End)
Dim_ReferralActions (ReferralActionTypeKey, ReferralProgramKey, Action Name)
This follows a more traditional approach, separating measurable business events.
Fact_Interventions (Granularity: One row per intervention)
Fact_Referrals (Granularity: One row per referral)
Fact_ReferralPrograms (Granularity: One row per referral program)
Fact_ReferralActions (Granularity: One row per action in a program)
Common Dimensions
Hi @scoobymoo1 ,
Your scenario is quite complex due to the hierarchical nature of interventions, referrals, programs, and actions. Let's break it down and explore the best approach.
This is the approach you proposed—having one central fact table with each previous step as a dimension.
Fact_ReferralProgramActions (Granularity: One row per referral program action)
Dim_Children (Child-related data)
Dim_Calendar (Dates for analysis)
Dim_Interventions (InterventionKey, ChildKey, Type, Start, End)
Dim_Referrals (ReferralKey, InterventionKey, Type, Start, End)
Dim_ReferralPrograms (ReferralProgramKey, ReferralKey, Type, Start, End)
Dim_ReferralActions (ReferralActionTypeKey, ReferralProgramKey, Action Name)
This follows a more traditional approach, separating measurable business events.
Fact_Interventions (Granularity: One row per intervention)
Fact_Referrals (Granularity: One row per referral)
Fact_ReferralPrograms (Granularity: One row per referral program)
Fact_ReferralActions (Granularity: One row per action in a program)
Common Dimensions
Thank you, I think I'll go with the single FACT table and hope it works this time!
I suggest trying your idea and see if you get the correct measure results you are looking for. I think people on here can give you at least 3-4 variations of a design (and some experience with some things that have failed). But, until you try something, you will never know.
Thanks, I'll give it a go. I'm just worried about spending too much time building dud models! I've already created a couple of failures!
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code FABINSIDER for a $400 discount!
Check out the February 2025 Power BI update to learn about new features.
User | Count |
---|---|
126 | |
113 | |
71 | |
65 | |
46 |