Forum Discussion

crsjunior's avatar
crsjunior
Advocate I
4 years ago
Solved

Relationship error while updating on server

I have a report that's updating fine on desktop, but on server I get this error: this is not allowed for columns on the one side of a many-to-one relationship or for columns that are used as the primary key of a table.

I've checked the column and there's no duplicated value. Even not apearing in database, I also went on the SQL Query and filtered to not bring the specified value that's duplicated, and when I try to update on server, it shoots another value. 

Below the complete column and relationship:

 

Already tried to delet and re-publish, change the logic on filtering unique values...nothing worked. 

  • I've solved it! 

     

    Still don't know the reason of the error. 

    I had to filter on the dimension table query, to not bring the Buyer_code that only apears on the fact table of the many-to-one relationship.

4 Replies

  • Hi crsjunior 

     

    For some reason there is a duplicate value on your table.


    What I would suggest doing is to refresh the entire dataset. 

     

    Then create a table with your column in the join. Then also count the number of times the same column details are in. What you might find is the value in the column which has got more than one value.

    • crsjunior's avatar
      crsjunior
      Advocate I

      Hello, GilbertQ

       

      I don't get it, on desktop the dataset updates without appearing this error.

       

      It seems to be some kind of bug, the first value shown as duplicated was the 'C21'. To test I've filtered on SQL to not bring C21, and when republished was shot the same error but with a diferent value. 

       

      You can see with this measure there's not any duplicated value. 

       

      Could it be some trash memory on service? 

       

      • GilbertQ's avatar
        GilbertQ
        Super User

        Hi crsjunior 

         

        Instead of the countrows, could you drag in your column COD_COMPRADOR again and then select COUNT from that to see?

  • I've solved it! 

     

    Still don't know the reason of the error. 

    I had to filter on the dimension table query, to not bring the Buyer_code that only apears on the fact table of the many-to-one relationship.