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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
datacauts
Helper I
Helper I

Joining tables - ID Table and Information Table with Text, number and CSValues

Hello guys.

 

Been having an issue here and I'll try to explain with some examples.

 

I have this table below:

datacauts_0-1625512202674.png

This comes from a CRM. So I have some information that is manually inputed (text) and some information that enters by a list classification (the numbers). For example in the Column "Estado Civil" we have the "Civil State" and the numbers means if the person is Married, Divorced or Single. For some cases, the system can input more than one answer for a question, so it enters with a >comma<, like in the "Melhor forma de contato" column ("best way to get in touch" - whatsapp, email, among others...).

 

Then I have this other table LabelsID

datacauts_1-1625512510880.png

The labelsID table takes care only of those number cases, so I can't pivot my original table and merge them because it don't recognize the values in columns like "Rua". Also, I have the comma problem, because in the Merge case it don't recognize the commas and gives me an error.

 

So is there a way of replacing the keys in my original table by the Label column?

I have made it close in Power Query but my query had like 50 steps, so it's not solid and reliable if some data changes...

 

Many thanks for the help!

 

 

2 ACCEPTED SOLUTIONS
mwegener
Most Valuable Professional
Most Valuable Professional

Hi @datacauts,

 

this is a use case for many-to-many relationship. A table with the CRM contacts, a table with the labels and a bridge table with the mapping from CRM contact to label.

 

Did I answer your question?
Please mark my post as solution, this will also help others.
Please give Kudos for support.

Marcus Wegener works as Full Stack Power BI Engineer at BI or DIE.
His mission is clear: "Get the most out of data, with Power BI."
twitter - LinkedIn - YouTube - website - podcast - Power BI Tutorials


View solution in original post

mwegener
Most Valuable Professional
Most Valuable Professional

You have to split the column in the bridge table to several rows with "Split Column by Delimiter".

SplitByDelimiterRow20210708.png

Did I answer your question?
Please mark my post as solution, this will also help others.
Please give Kudos for support.

Marcus Wegener works as Full Stack Power BI Engineer at BI or DIE.
His mission is clear: "Get the most out of data, with Power BI."
twitter - LinkedIn - YouTube - website - podcast - Power BI Tutorials


View solution in original post

3 REPLIES 3
mwegener
Most Valuable Professional
Most Valuable Professional

You have to split the column in the bridge table to several rows with "Split Column by Delimiter".

SplitByDelimiterRow20210708.png

Did I answer your question?
Please mark my post as solution, this will also help others.
Please give Kudos for support.

Marcus Wegener works as Full Stack Power BI Engineer at BI or DIE.
His mission is clear: "Get the most out of data, with Power BI."
twitter - LinkedIn - YouTube - website - podcast - Power BI Tutorials


mwegener
Most Valuable Professional
Most Valuable Professional

Hi @datacauts,

 

this is a use case for many-to-many relationship. A table with the CRM contacts, a table with the labels and a bridge table with the mapping from CRM contact to label.

 

Did I answer your question?
Please mark my post as solution, this will also help others.
Please give Kudos for support.

Marcus Wegener works as Full Stack Power BI Engineer at BI or DIE.
His mission is clear: "Get the most out of data, with Power BI."
twitter - LinkedIn - YouTube - website - podcast - Power BI Tutorials


I tried that but unfortunately the relationship activated by the Bridge table do not recognize the comma cases, like a value "66, 67" in one row or "99,101".

Helpful resources

Announcements
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!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.