Forum Discussion

RichardSLF's avatar
RichardSLF
Regular Visitor
8 years ago
Solved

Copy data in group with same ID, but missing data in one row

Hello all,

 

I have a following table:

Contact No_Business Relation CodeLink to TableNo_
KON00003ZAK0 
KON00003OV021Z04482
KON00005OV020 
KON00005ZAK1Z04484

Where I have dupicate values in Contact No_ and would like to copy the corresponing data in No_ to the empty field, so it should look like this after the query, I appreciate any help with this. Thanks.

Contact No_Business Relation CodeLink to TableNo_
KON00003ZAK0Z04482
KON00003OV021Z04482
KON00005OV020Z04484
KON00005ZAK1Z04484
  • RichardSLF

     

    Try this calculated column

     

    New No =
    CALCULATE (
        LASTNONBLANK ( TableName[No_], 1 ),
        FILTER (
            ALL ( TableName ),
            TableName[Contact No_] = EARLIER ( TableName[Contact No_] )
        )
    )

2 Replies

  • Zubair_Muhammad's avatar
    Zubair_Muhammad
    Icon for Community Champion rankCommunity Champion

    RichardSLF

     

    Try this calculated column

     

    New No =
    CALCULATE (
        LASTNONBLANK ( TableName[No_], 1 ),
        FILTER (
            ALL ( TableName ),
            TableName[Contact No_] = EARLIER ( TableName[Contact No_] )
        )
    )