Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Combine two measures with two common dimension plus time


Combine two measures with two common dimension plus time

Author
Message
Paul Hernández
Paul Hernández
SSC-Enthusiastic
SSC-Enthusiastic (173 reputation)SSC-Enthusiastic (173 reputation)SSC-Enthusiastic (173 reputation)SSC-Enthusiastic (173 reputation)SSC-Enthusiastic (173 reputation)SSC-Enthusiastic (173 reputation)SSC-Enthusiastic (173 reputation)SSC-Enthusiastic (173 reputation)

Group: General Forum Members
Points: 173 Visits: 654
Hi folks,

It was difficult to select the appropriate title for my question.

Background: The business analyst specify the following report (this is the simplified version):


Also to simplify sopose that I have two "Fact Tables"
- Purchase Orders:


- Inventory:


The challenge: I'm trying to build a cube in order to create a powerpivot report that looks like in the specs.

The drawback: the purchase orders table and the inventory table have both the Article and Country dimension. The problem arises when I want to include the time dimension in the pivot, because the inventory is not related to the time dimension.

Alternative 1: we added a dummy time id to the inventory table and then we could hide columns in the report with NULL values

Alternative 2: include the quantity or sold articles in the purchase order pro month as a calculated member

I'm not satisfy with this solutions and I think I'm missing something here from the theory.

Any comment or suggestion about how to tackle this issue will be appreciated.

Kind Regards,

Paul Hernández
sneumersky
sneumersky
SSCrazy
SSCrazy (2.2K reputation)SSCrazy (2.2K reputation)SSCrazy (2.2K reputation)SSCrazy (2.2K reputation)SSCrazy (2.2K reputation)SSCrazy (2.2K reputation)SSCrazy (2.2K reputation)SSCrazy (2.2K reputation)

Group: General Forum Members
Points: 2174 Visits: 487
Inventory measures are usually modeled based on:

1. A periodic snapshot fact table at a daily or monthly date grain and sometimes.....
2. An accumulating snapshot done for the current month.


A semi-additive measure such as LastNonEmpty or LastChild is usually used to measure the inventory on hand at the end of each period.

One measure group would use the purchase orders fact table and....
One measure group would use the inventory fact table.

Are you SURE you do not have any historical data regarding inventory (no auditing history of previous quantities on hand?)
Sushil Dwivedi
Sushil Dwivedi
SSC Rookie
SSC Rookie (37 reputation)SSC Rookie (37 reputation)SSC Rookie (37 reputation)SSC Rookie (37 reputation)SSC Rookie (37 reputation)SSC Rookie (37 reputation)SSC Rookie (37 reputation)SSC Rookie (37 reputation)

Group: General Forum Members
Points: 37 Visits: 142
i would suggest to use date dimension as a confirmed dimension with 2 fact tables. Create a dateid key in inventory fact table and use date dimension as confirmed dimension(shared dimension)
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search