Forum Discussion

deisterBI's avatar
deisterBI
Frequent Visitor
3 years ago
Solved

Copy text from within table

Hi, I would like to refference the Main component within a parts list The mother article doesnt hold stock but the doughter article does. I would like to have the name of the doughter article in ...
  • Anonymous's avatar
    Anonymous
    3 years ago

    Hi deisterBI ,

    If you want to add a new column, you also just need to adjust my measure simply, please try below dax formula:

    Article Column =
    VAR cur_monarticle = 'Table'[Mother article]
    VAR tmp =
        FILTER ( ALL ( 'Table' ), 'Table'[Mother article] = cur_monarticle )
    VAR max_sale =
        MAXX ( tmp, [Sales] )
    VAR article =
        CALCULATE (
            MAX ( 'Table'[Doughter article] ),
            FILTER ( ALL ( 'Table' ), 'Table'[Sales] = max_sale )
        )
    RETURN
        article
    

    Please refer the attached .pbix file.

     

    Best regards,
    Community Support Team_ Binbin Yu
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.