Forum Discussion
MyNameHere2213
2 years agoRegular Visitor
How to Sum by field on different table
I'm trying to create a measure that will Sum the forecasted and actual proceeds a client receives for all of the companies they own. Data model is structured in a star schema with Clients as t...
audreygerred
Super User
2 years agoHi! In a star schema the DIM tables are the 1 side on 1:M. Your fact table should be the many and ideally, avoid bi-directional joins.
Is Client ID the key for Sub-category? What granularity level is that dim table at? What level of granularity is actual and forecast at?
- MyNameHere22132 years agoRegular Visitor
It's been a while since I've done this, you are correct maybe I should look at restructuring my model.
ClientID is a FK for the Client table that contains various information about the client (name, location, email, etc.). The actual and forecasted tables are granular to a specific transaction and I can see what they should have received and actually received for every transaction that occurred.