Forum Discussion
Merging tables from a database - Difference between "Value" and "Table"?
- 4 years ago
Hi Anonymous
When you connect to the database at the first time, expand Advanced options and uncheck Include relationship columns option. By default, this option is checked and it will import linked tables into Power BI. That's probably why you see so many unexpcted linked tables.
For Merge Queries tutorials, you could refer to below links:
Merge queries overview | Microsoft Docs
Append vs. Merge in Power BI and Power Query - RADACAD
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
Hi v-jingzhang,
Thanks a lot for your reply!
I just tried your solution and it seems to work fine. The merge operation output is less messy now, as it doesn't show tens of unwanted columns from tables I didn't intentionnally load.
However, doing this means I lose the relationships between the tables I imported as well.
Isn't there a midway solution where I could still have these relationships (which are helpful as a reference to know the keys when merging) but not having relationships with other tables I didn't load?
Many thanks
Antoine
Hi Anonymous
Navigate to File > Options and settings > Options from Power BI Desktop, and select Data Load in the left pane. Check Import relationships from data sources on first load option. This will import existing relationships between imported tables from data source.
If it doesn't import relationships on first load, you can still create a relationship manually or with autodetect in Power BI Desktop. It's very flexible.
Reference:
Create and manage relationships in Power BI Desktop - Power BI | Microsoft Docs
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
- Anonymous4 years agoNot applicable
Thanks for your swift reply!
I already had this option ticked/activated.So it seems that it's an all or nothing situation (whether have all the relationships even unwanted ones or no relationships at all).
The advanced option "Include relationship columns" from the connexion pane seems to overwrite the "Import relationships from data source on first load" from the options pane.
If there is something I am missing here, I am still interested in knowing the solution.
If this is indeed how PowerBI works, it may need to be improved.
Thanks anyway for your support!
If I am missing someting- v-jingzhang4 years agoCommunity Support
Hi Anonymous
I didn't notice this before. Do the tables you want to import have relationships (foreign keys) between each other directly, not through other unimported tables?
Jing
- Anonymous4 years agoNot applicable
Yes, they all have relationships between each other directly!