Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

attribute parent-child relationships

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
how do one give Parent-Child relationships in Attribute Creation Wizard. when i select a attribute and select children it shows all the available childrens i.e. it shows attributes from the same table itself. is it necessary to select those attributes as well or how to give relationship if we have a table which contains composite primary key with some of them being foreign keys. any suggestions.

windie
 
For a straight forward attribute, I would use the wizard.
For compound attributes, or heterogeneous column names I would use the attribute editor. The wizard is primarily useful for creating simple attributes that have one lookup table and the column names of the parent/child lookup tables are the same.
 
thanks but i couldn't understand your reply.suppose i have a sample tables like the one given below can you explain how the relationships should be.

Table A Table B

Column1 PK Column2 PK FK to Table A
Column2 PK Column5
Column3 Column6
Column4

now if i select Column4 and select childrens it displays Column3, Column2, Column1. now how do i give the relationship in this case. i would like to know is it really necessary to give relationship for Column4 if not where do i start. can you tell me the relationships that i have to do for tables like one above where i use all the columns.

many thanks

windie
 
My suggestion is to not think about table columns yet, but to think in terms of attributes. An attribute is an entity like "product" that you need to group by, or filter on. Attributes generally can have multiple "forms". An ID is an attribute form, so is a description, a URL, image etc...so a product is ONE attribute with an ID form, a URL form, an image form... you get the idea. You can choose which form to show in reports and when you're browsing.

So let's say column 1 represents the ID of attribute A1, and column 2 represents the ID of attribute A2. When you create A1, it defaults to asking you for the ID form of A1 and you choose tableA and column 1. No big deal, but remember you can also specify other forms.

Then when you create attribute A2, it does the same thing but you should see tableA and B listed. In one of the tabs, you now specify parent, and you'd choose A1.

this should work. After you're done make sure to "update schema" before creating reports.
 

nlim thanks! but my question is if i create a attribute A4 which represents Column4 in Table A and attribute A6 which represents Column6 in Table B now if i select childrens for Column4 it shows Column2, Column1 and for Column6 it shows Column2. now should i give relationships for these attributes which are not PK or FK at the table level? if so, how should the relationship be like.

thanks

windie
 
is column 2 just a dummy column, or does it mean something like "product"?

The issue with MSTR is that you cannot think in terms of columns, it is very confusing that way. I'm going to take your table structure and put some example names in it.

Table A Table B
C1 (Year)PK C2 (Quarter)
C2 (Quarter)PK C5
C3 C6 (Month)
C4 (Fiscal Quarter)

Now say you create an attribute for C4 called Fiscal quarter, and C6 called month. These 2 are completely unrelated so you cannot see which months are in each fiscal quarter. WHat you have to do in this case is to make Fiscal quarter a parent of quarter, AND make quarter a parent of Month. Then you'll be able to see all the months for each fiscal quarter.

I hope this makes it easier...

If you don't need to see which months are in each fiscal quarter, than I would leave the attribute for C4 and C6 separate as they are logically separate attributes.

If it's still not clear you might want to consider an training class with MSTR. My experience shows that the class pays for itself in 2 months of saved time!


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top