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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

change text value of one column as other column value

Hello ,
I have two different tables 1(data table) 2(standard table) , i want dealer name from data table to be same as mentioned n standard table to make a join .sharing an image with dummy data.
Thank you in advance

 Capture 30 march23.PNG

8 REPLIES 8
tamerj1
Super User
Super User

Hi @Anonymous 
The example provided seems to be over simplified. This is one is easy to handle but I guess the real data is much bigger with much more variations. Please provide a descent amount of editable sample data that really reflects all the possible cases.

Anonymous
Not applicable

Hello @tamerj1 ,
Thank you for your reply , sharing link to the editable file 
https://docs.google.com/spreadsheets/d/1tZd7UxrheU39KNfTJXsqXyT9T3tJpgYc/edit?usp=sharing&ouid=10564... 

@Anonymous 

code is required to access the file 

Anonymous
Not applicable

@tamerj1 you can access the file now

 

Hi @Anonymous 
Please refer to attched sample file with the proposd solution.

1.png

Dealer (Standard) = 
VAR String1 = Table1[Dealer]
VAR Items1 = SUBSTITUTE ( String1, " ", "|" )
VAR Length1 = COALESCE ( PATHLENGTH ( Items1 ), 1 )
VAR T1 = GENERATESERIES ( 1, Length1, 1 )
VAR T2 = SELECTCOLUMNS ( T1, "@Item", PATHITEM ( Items1, [Value] ) )
VAR T3 = 
    ADDCOLUMNS ( 
        Standard,
        "@%Match",
        VAR String2 = Standard[Dealer]
        VAR Items2 = SUBSTITUTE ( String2, " ", "|" )
        VAR Length2 = COALESCE ( PATHLENGTH ( Items2 ), 1 )
        VAR T4 = GENERATESERIES ( 1, Length2, 1 )
        VAR T5 = SELECTCOLUMNS ( T4, "@Item", PATHITEM ( Items2, [Value] ) )
        VAR T6 = INTERSECT ( T5, T2 )
        RETURN
            DIVIDE ( COUNTROWS ( T6 ), COUNTROWS ( T5 ) )
    )
VAR T7 = TOPN ( 1, T3, [@%Match] )
RETURN
    MAXX ( T7, Standard[Dealer] )

 

 

Anonymous
Not applicable

I have shared complex data is other sheet of the file ,Plwase check 

 

@Anonymous 

Same solution is working. I have updated the sample file my the original reply with the detailed data. Seems to work just fine. Please refer to my original reply for the updated sample file

Anonymous
Not applicable

@tamerj1 please send me a request for an access

 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.