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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Mariam1991
Helper II
Helper II

JOIN 3 tables

Hi everyone;

I have 3 tables i need to join its to calculte distinct id  in table A distinctcount(tableA[id]) but the juncture will be between 3 tables  as below:

tableA[id]=max(tableB[id])

tableB[id]=tableC[id]

 I need your help

10 REPLIES 10
gopichilla
Resolver III
Resolver III

Can you check with this option Edit Queries in Power BI Desktop->

2017-05-30_18h30_53.png 

https://community.powerbi.com/t5/Desktop/Merge-queries/td-p/151692

 

It helps to you.

 

Thanks

Thank your for your feedback , i dont need to merge tables but i need to calculate a measure with the juncture between 3 tables

can you post sample data of your tables?

3 tables.PNGi don't know how but my aim is to calculate distinct id in table A taking in consideration the juncture between 3 tables 

Hi @Mariam1991,

 

Could you post your table structures with some sample data and your expected result? So that we can better assist on this issue. Smiley Happy

 

Regards

HI

thank for your help , i have 3 table A, B and C  the meaure need a juncture between them as you will see total souscrpition by sex , by group age  are in table C but the measure i should calculate distinct id in table A , the juncture :

inner join table B on max(tableB[id])=tableA[id]

inner join table C on tableB[id]=tableC[the structure of 3 tablesthe structure of 3 tablesid]total souscription by group age but the calcul is false :(total souscription by group age but the calcul is false 😞

Hi @Mariam1991,

 

Could you also post some sample data for the three tables and the expected result against the sample data? Smiley Happy

 

Regards

Hi,

To facilitate a little my problem, i need to transform a SQL query into a measure in power BI , i have 3 tables,i would calculate count Id in table A by age or sexe which are in table C the problem there is no direct relationship between them , i have to go through table B 

table A (ID)>>table B(ctr_id)>> tablec(id)

my queqy is : 

select C1.sexe, count (A1.ID) from table A A1

inner join table B B1 on B1.ctr_id=A1.ID

inner join table C C1 on C1.id=B1.id

where A1.status='payed' and B1.id=  (select max(id) from table B B2 where B2.ctr_id=A1.ID)

group by C1.sexe

 

Really im blocked, thank your for your help

HI;

Not yet, i'm always blocked 😞

@Mariam1991: Yes you please provide more details, I did not understand your requirement properly.

 

 

Thanks,

Sunkari

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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