Forum Discussion

jja's avatar
jja
Icon for Helper III rankHelper III
4 years ago

relationship between tables gets inactive

Hi 

I have tables loaded from dataverse nd one relationship is inactive and that gives me wrong results

If i try to make it active it says: you can't create a direct relationship between because an active set of indirect relationships already exists.

my model looks like this:

Components linked to projects during projectsid, components linked to transactiopns using componentsid and i want to link projects and tranbsactions(as it is in dataverse) using pojectsid

 

Without this link if i calculate how many components are processed in transction table for each projects and if i have in some which i have components name not uniqie(means same name in different projects) it gives me wrong results. It calculates this components for each project where it exists. I do understand this is relationship problem.

Can somebody help to solve it?

 

2 Replies

  • jja , Ideally new componenets and new transactions should not join.

     

    Or you should have two copies of new componenets one as fact and one as dimension

     

    or merge new componenets  and new transactions

  • jja's avatar
    jja
    Icon for Helper III rankHelper III

    Hi amitchandak 
    Yes i already understood that joining is not a good idea. I havew removed this relationship and i get better results but now i have one issue with creating a calculation:

    In my transactions i have component name and qty and i wan to calculate the total weight weight of this qty. Weigt is stored for this component in components table. How should i make this calculation.

    It should look liek this

    Processed weight=new_transactions[qty]*new_components[weight]. but i can not find how to reach newcompnents[weight] column