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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Anonymous
Not applicable

Determine a new column based on other table lines

Hi everybody,

 

I'm trying to determine a new column based on information of multiple lines from another table.

I really do not know how to do that and would appreciate your help.

 

You'll find an image to show what I expect.

 

In green -> 'Fixe' when all the lines for the 'Paquet' in column 'Longueur' are the same

In blue ->'Variable' when all the lines for the 'Paquet' in column 'Longueur' are not the same

 

SANTEKEK_0-1650544776984.png

 

 

 

Thanks for your help.

 

1 ACCEPTED SOLUTION
philouduv
Resolver III
Resolver III

Hey @Anonymous ,
If you just need to fill the second table type and that the first column is created with the differents paquet use :

Type= CALCULATE(IF(DISTINCTCOUNT(Table1[longueur]) == 1, "Fixe","Variable"))

Best regards

View solution in original post

3 REPLIES 3
philouduv
Resolver III
Resolver III

Hey @Anonymous ,
If you just need to fill the second table type and that the first column is created with the differents paquet use :

Type= CALCULATE(IF(DISTINCTCOUNT(Table1[longueur]) == 1, "Fixe","Variable"))

Best regards

amitchandak
Super User
Super User

@Anonymous , Try like a new column in Table 1

 

maxx(filter(Table2, Table1[Paquet] = Table2[Paquet]), Table2[Type])

 

refer 4 ways to copy data from one table to another
https://www.youtube.com/watch?v=Wu1mWxR23jU
https://www.youtube.com/watch?v=czNHt7UXIe8

Anonymous
Not applicable

SANTEKEK_0-1650546318405.png

 

 

Thanks @amitchandak ... I think my image was not clear enough...

 

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.