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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
deisterBI
Frequent Visitor

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 the same row as the mother article to link it with my purchasing table.

Articlepartsdoes hold stockqty orderedMain Article
12345ABCD11000ABCD
123451234500ABCD

 

The goal would be to achive what is stated in the colum "main Article"

Any Ideas :)?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

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

vbinbinyumsft_0-1669081341716.png

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.

View solution in original post

9 REPLIES 9
Anonymous
Not applicable

Hi @deisterBI ,

Please try below steps:

1. below is my test table

Table:

vbinbinyumsft_0-1668479488634.png

 

2. create measure with below dax formula

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

3. add a table visual with fields and measure

vbinbinyumsft_1-1668479574431.png

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.

 

just to make this more transparant, with more than one mother article:
the collum main article would again be my desired outcome.

 

mother articleDoughter articlesalesmain article
cardoor2tires
cartires4tires
carwheel2tires
truckdoor2windshield
trucktires4windshield
truckwheel2windshield
truckwindshield6windshield
Anonymous
Not applicable

Hi @deisterBI ,

You just need to adjust my measure simply, please try below dax formula:

Main Article =
VAR cur_monarticle =
    SELECTEDVALUE ( '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

vbinbinyumsft_0-1669023285423.png

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.

 

amazing.
and if I wanted to have that same result, as a collum in the table itself not as a messure ?

I would need to have that field in order to link it in the datamodell with another table.

Anonymous
Not applicable

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

vbinbinyumsft_0-1669081341716.png

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.

@Anonymous 
Now that i ran some tests, i came across a problem:
when another daughter article in another part list, has the same sales as the maximum one in another part list, those get switched up at times.

The only link between both datasets seems to be the qty in sales.
I thought that the variables you defined, prefented that exact result, but apparently it is possible that the formula only matches the daughter article number based on the max sales and somehow is ignoring the mother article parameter.

i am super lost here, if you can help once again , that would be great 🙂

 

you made my day , thank you so much !

HI @Anonymous,

thank you for taking the time to help me.
So far , I am not getting the results needed, and its probably because there are multiple "mother articles".

the messure now gives me the most selling "doughter article" but its not correlating with the "mother article"

So for all mother articles I get the same result which is the most selling doughter article. (even when that part isnt in the part list of the mother article)
i think we are close , in case I didnt make any mistake converting the abstract formula, there is missing the part where the mother article is beeing refferenced ?

Thanks again for your help

deisterBI
Frequent Visitor

Mother articleDoughter articleSales"main Article" 
cartires2wheel 
carwheel4wheel 
cardoor2wheel 


maybe I need to descripe the situation better ?

I would need the result as in the collum "main article"
I want to add the article name of the most "contributing" article of a data group

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.