Design Tip #17 missing
3 posters
Page 1 of 1
Design Tip #17 missing
I have seen reference to design tip #17 in a number of forum posts (it covers Populating Hierarchy Helper Tables) but when I follow through the links I get a 404 error (not found).
Does anyone know where this design tip has gone? or have a copy?
Does anyone know where this design tip has gone? or have a copy?
glenncogar- Posts : 4
Join date : 2015-03-09
Location : Sydney, Australia
Re: Design Tip #17 missing
Design Tip #17 wasn't written by the Kimball Group so its no longer on our website however Ralph did write a similar article:
http://www.kimballgroup.com/wp-content/uploads/2014/11/Building-the-Hierarchy-Bridge-Table.pdf
I hope this helps!
Nancy
http://www.kimballgroup.com/wp-content/uploads/2014/11/Building-the-Hierarchy-Bridge-Table.pdf
I hope this helps!
Nancy
Re: Design Tip #17 missing
Thanks Nancy
glenncogar- Posts : 4
Join date : 2015-03-09
Location : Sydney, Australia
Re: Design Tip #17 missing
Hi again Nancy, in the article you sent me (written by Ralph) the SQL statement at the end includes a
,REPEAT('',LEVEL*5)||LEVEL||'-'||Company_Name AS COMPANY_LOGICAL_TREE
line. I think the REPEAT function is a SQL SERVER feature and I'm using MySQL. I think I can replace it but I don't understand what the REPEAT(...) part is trying to do. If I remove it i.e.
,LEVEL||'-'||Company_Name AS COMPANY_LOGICAL_TREE
then the rows in the output include column values of (for example) 6 - IBM ... where 6 is the LEVEL and IBM is the Company_Name. I understand what that would mean i.e. IBM is the company name of a node at level 6 in the tree structure generated
the REPEAT part would appear to generate a value of LEVEL*5 (=30 in my example) spaces (the value between the ' ' in the REPEAT function). So I guess its creating 'padding' for a visual effect ? Is that correct?
Also, in case anyone else is using MySQL the 'FETCH FIRST ROW ONLY' part of the SQL can be replaced with 'LIMIT 1'
Thanks for any help on this, just want to check my understanding
,REPEAT('',LEVEL*5)||LEVEL||'-'||Company_Name AS COMPANY_LOGICAL_TREE
line. I think the REPEAT function is a SQL SERVER feature and I'm using MySQL. I think I can replace it but I don't understand what the REPEAT(...) part is trying to do. If I remove it i.e.
,LEVEL||'-'||Company_Name AS COMPANY_LOGICAL_TREE
then the rows in the output include column values of (for example) 6 - IBM ... where 6 is the LEVEL and IBM is the Company_Name. I understand what that would mean i.e. IBM is the company name of a node at level 6 in the tree structure generated
the REPEAT part would appear to generate a value of LEVEL*5 (=30 in my example) spaces (the value between the ' ' in the REPEAT function). So I guess its creating 'padding' for a visual effect ? Is that correct?
Also, in case anyone else is using MySQL the 'FETCH FIRST ROW ONLY' part of the SQL can be replaced with 'LIMIT 1'
Thanks for any help on this, just want to check my understanding
glenncogar- Posts : 4
Join date : 2015-03-09
Location : Sydney, Australia
Re: Design Tip #17 missing
Hi glenncogar,
I'm afraid my days of writing/understanding SQL are long passed. Perhaps another Forum member is better qualified to reply to your question.
Fingers crossed,
Nancy
I'm afraid my days of writing/understanding SQL are long passed. Perhaps another Forum member is better qualified to reply to your question.
Fingers crossed,
Nancy
Re: Design Tip #17 missing
You are correct. The repeat is simply to indent the name to follow the hierarchy.
Re: Design Tip #17 missing
Thanks ngalemmo
glenncogar- Posts : 4
Join date : 2015-03-09
Location : Sydney, Australia
Similar topics
» Main dimension and profile dimension
» Historical Measures Missing
» Dealing with empty/missing dates in dimensions
» Modelling Product Dimension when incoming fact records have missing lowest level
» Reasons to use a 3NF design over a Dimensional Model design for an EDW - Discussion
» Historical Measures Missing
» Dealing with empty/missing dates in dimensions
» Modelling Product Dimension when incoming fact records have missing lowest level
» Reasons to use a 3NF design over a Dimensional Model design for an EDW - Discussion
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum
|
|