Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I am a QV newbie and after I found a solution to my earlier problem (look here : http://community.qlik.com/message/202612 )
I encountered yet another one.
Since I have duplicated my Site table (referred as to "Location" in the previous example) I now have 1 link between Site_From and Transport, plus another link between Site_To and Transport, but that gives me a loop as shown here :
Though my original (MS Access) database model looks like this :
As explained in the previous thread, I need to have such double relationships because in Transport for example, I need to know the shipping goes from where, to where. Therefore to create relationships in QV I had to duplicate the table Site, and finally got a loop problem, is there any workaround?
I don't understand how I can solve this issue, I am new to QV,
thanks for your time
I think it is correct to have two separate branches for "Name_Site_To" and "Name_Site_From". You just need to take it all the way...
In other words: you need to have two City tables too, and link the City tables correctly to the "Name_Site_xx" tables. So you will have one branch for the "To" fields: "Name_Site_To" <--> "City_To" and an identical for the "From" fields. And you need to rename the "Name_Country" into "Name_Country_To" and "Name_Country_From".
Only this way can you make a selection where "Name_Country_To" has a different selection than "Name_Country_From".
/HIC
Without getting into your requirements and information, what I think I'd do is concatenate both site tables and leave them with a "direction" identifier field, for example:
Name_Site
Name_City
PlantNumber_Site
ITCostPerEmployee_Site
WrapRate_Site
"Direction" (From, To)
and link that table to your Transport table
I think it is correct to have two separate branches for "Name_Site_To" and "Name_Site_From". You just need to take it all the way...
In other words: you need to have two City tables too, and link the City tables correctly to the "Name_Site_xx" tables. So you will have one branch for the "To" fields: "Name_Site_To" <--> "City_To" and an identical for the "From" fields. And you need to rename the "Name_Country" into "Name_Country_To" and "Name_Country_From".
Only this way can you make a selection where "Name_Country_To" has a different selection than "Name_Country_From".
/HIC
It would work if I needed to have a Site_From link XOR a Site_To link in my Transport table, but it is not the case since I need to have both. But I cannot have 2 links (from 2 fields in the Transport table) going to the same field in Site unfortunately (because of how QV makes associations)
I completely "forked" the table relationships all the way as you said.
It now looks like this
And I no longer have a loop warning, thank you!