dbTalk Databases Forums  

dimension relationship

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss dimension relationship in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Marty
 
Posts: n/a

Default dimension relationship - 11-21-2006 , 01:52 PM






I have a dimension that I just can’t get to relate to my fact table. Here is
the setup:

Customer Table
Customer_no (pk)

Order Table
Order_no (pk)
Customer_no

Lineitem Table
Lineseq_no (pk)
Order_no

Sublineitem Table (Fact)
Sli_no (pk)
Lineseq_no

I don’t know if this is even possible, but I am trying to get the customer
dimension to relate to the fact table but can’t get it to work. I have
created dimensions for customer, order, and lineitem with lineitem as a
regular relationship type and everything else as a referenced relationship
type. Is this the wrong way to go about it or am I just missing something
simple? My end goal is to take totals sales from sublineitem and break it out
by customer attributes like Gender and eventually break it out by postal code
from my address table which is joined to customer. Thanks for the help,

--
Marty

Reply With Quote
  #2  
Old   
Marco Russo
 
Posts: n/a

Default Re: dimension relationship - 11-22-2006 , 01:22 PM






Marty,

referenced dimension are not intended to solve the problem that you
have not designed a star schema.
I don't know if you can use referenced dimensions in a chain like your
scenario, but what you should be do is to have a fact table with
customers directly related to it. If you really don't want (or cannot)
create a real star schema, than you can solve the problem by creating a
view that join Order/LineItem/SubLineItem and using that as fact table.

Marco Russo
http://www.sqlbi.eu
http://www.sqljunkies.com/weblog/sqlbi

Marty ha scritto:

Quote:
I have a dimension that I just can't get to relate to my fact table. Here is
the setup:

Customer Table
Customer_no (pk)

Order Table
Order_no (pk)
Customer_no

Lineitem Table
Lineseq_no (pk)
Order_no

Sublineitem Table (Fact)
Sli_no (pk)
Lineseq_no

I don't know if this is even possible, but I am trying to get the customer
dimension to relate to the fact table but can't get it to work. I have
created dimensions for customer, order, and lineitem with lineitem as a
regular relationship type and everything else as a referenced relationship
type. Is this the wrong way to go about it or am I just missing something
simple? My end goal is to take totals sales from sublineitem and break it out
by customer attributes like Gender and eventually break it out by postal code
from my address table which is joined to customer. Thanks for the help,

--
Marty


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.