Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
danextian
Super User
Super User

Prevent Power BI from chaging direction of a relationship

Hello,

 

I have an Invoice table which contains a column that holds the unique ID's to link to other tables (overpayment, prepayment and payment, creditnote). Each of the other table contains one or more rows of the same Unique ID and each Unique ID in a table cannot be found in all other tables.

 

I created four relationships with invoice table on the one side of thse relationships:

  • invoice[unique id] to overpayment[unique id]
  • invoice[unique id] to prepayment[unique id]
  • invoice[unique id] to payment[unique id]
  • invoice[unique id] to creditnote[unique id]

After applying/saving these relationships though, I wondered why I coundn't use all these columns in a table visual. It turns out that Power BI has reversed the relationships. Any idea how to prevent this?










Did I answer your question? Mark my post as a solution!


Proud to be a Super User!









"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.
6 REPLIES 6
parry2k
Super User
Super User

@danextian based on your input, you have invoice on one side of relationship and all other tables on many side, correct?

 

if that is the case, you drop any column from invoice table and you can drop columns from other table and it will work. Not sure what the actual problem is?



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Hi @parry2k 

 

I have quite a lot of tables so it will be quite confusing to be using the relationship view so I instead tried adding the relationships using Manage relationships. The Invoice table was on the one-side prior to closing the dialogue box but was moved to many after closing it. The other tables are now on the one-side.










Did I answer your question? Mark my post as a solution!


Proud to be a Super User!









"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

@danextian That does't sounds right to me, I have no idea what your data looks like and I think that is the first thing to resolve



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Yes. It is. I can't proceed unless it's been resolved. I wish I could post the pbix but the data is very confidential. I'm using the Nov 2019  version of Power BI.










Did I answer your question? Mark my post as a solution!


Proud to be a Super User!









"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

@danextian Can you try to change the relationship by clicking the relationship line? If it is putting invoice on many side, it means thats how your data is , not sure wht else to tell, you have take small sample of your dataset and try to isolate the problem by connecting with one table. There is no other way to resolve it.



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Hi @parry2k ,

I realized my statement was incorrect. I set the direction to One-to-Many but after clicking OK on the dialogue box, the direction has changed to Many-to-One. Power BI did not change the sides but instead changed the direction so If I put invoice[Unique ID] and all other Unique ID columns in a table visual, Power BI returns an error saying that it can't determine the relationship between these columns. 










Did I answer your question? Mark my post as a solution!


Proud to be a Super User!









"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

Find out what's new and trending in the Fabric Community.

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

Check out the November 2024 Power BI update to learn about new features.