HELP - Getting a many to many relationship when it should be one to many

Hi team, having a problem trying to solve what should be an incredibly simple situation. When creating a link between two tables using an index column I am getting a many to many relationship despite one table only having one instance of the data.

I have made sure the data and format in the index column matches in both tables and is definitely singular in the index table. Has anyone else had this before?

@stevens Kindly share your pbix file as it is not clear what the problem is by just looking at the image.

Thanks.

Hi @stevens, we aim to consistently improve the topics being posted on the forum to help you in getting a strong solution faster. While waiting for a response, here are some tips so you can get the most out of the forum and other Enterprise DNA resources.

  • Use the forum search to discover if your query has been asked before by another member.

  • When posting a topic with formula make sure that it is correctly formatted to preformatted text </>. image

  • Use the proper category that best describes your topic

  • Provide as much context to a question as possible.

  • Include the masked demo pbix file, images of the entire scenario you are dealing with, screenshot of the data model, details of how you want to visualize a result, and any other supporting links and details.

I also suggest that you check the forum guideline https://forum.enterprisedna.co/t/how-to-use-the-enterprise-dna-support-forum/3951. Not adhering to it may sometimes cause delay in getting an answer.

Please also check the How To Mask Sensitive Data thread for some tips on how to mask your pbix file

Yearbook data[Club Index] column should have duplicate values or blank value. Please investigate on that column further. Also attach your .pbix file so its easy to give a exact answer.

1 Like

@stevens There are duplicates in the club index of both tables which is making both columns a foreign key, you will have to create a primary key in one of the table to get 1:Many setup.

I suppose the “Yearbook data” is your attribute table and the Facts is the “Catch” table.
With this assumption please have a look that there are not duplicate “Club Index” values into the “Yearbook Data” table, that should not be.
If there are duplicate you need to solve it, creating a further table and reduce the M-M relationship in a M-1-M type

luca

Hi @stevens, we’ve noticed that no response has been received from you since the 24th of November. We just want to check if you still need further help with this post? In case there won’t be any activity on it in the next few days, we’ll be tagging this post as Solved. If you have a follow question or concern related to this topic, please remove the Solution tag first by clicking the three dots beside Reply and then untick the checkbox. Thanks!

A response on this post has been tagged as “Solution”. If you have a follow question or concern related to this topic, please remove the Solution tag first by clicking the three dots beside Reply and then untick the check box. Thanks!

Hi team, thank you all for the help. The problem was found in the code used to create the index table. It kept creating a duplicate record. Now fixed. Sorry for any inconvenience.

cheers
Steven

1 Like