Good Morning,
I'm currently modeling an inventory control process and was hoping to get some input/feedback on breaking up a blended transaction table.
The source system has a single table that stores inventory transactions (this will obviously be the source for an inventory periodic snapshot table). There are a variety of transaction types in this table (inventory checkout, inventory return, stock adjustment,
move stock, etc). For each transaction there is a "ChargeToEntity" which can refer to a number of business entities depending on the transaction type.
For example, an "inventory checkout" transaction can be charged to a "work order", "employee", "equipment", or a "location". While a "stock movement" transaction can only be charged to a "location". Then there are the "manual price adjustment" transactions which aren't charged to anything (this is more for tracking the value of inventory on hand at various points in time).
I know I need to break the transactions into separate inventory-fact tables (ex. Fact Inventory Checkout, Fact Inventory Return, Fact Inventory Stock Adjustment, etc). However, should the fact tables for the transaction types that can be charged to multiple
different ChargeToEntities be further broken down?
For example, should the Fact Inventory Checkout table be broken down into:
Fact Inventory Checkout Charged To Employee
Fact Inventory Checkout Charged To Work Order
Fact Inventory Checkout Charged To Location
Or is that overkill? The other option being a single fact table with multiple ChargeTo fields:
Fact Inventory Checkout
Charge_To_Employee_Key
Charge_To_Work_Order_Key
Charge_To_Location_Key
BI Developer and lover of data (Blog | Twitter)