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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
CarlsBerg999
Helper V
Helper V

Propagating an ID

Hi,

 

I'm having difficulties creating a Calculated Column for a scenario: The goal is to create a dax for the result column. 

Each platform has atleast 1 Indicator markek as "X". If there are multiple "X"'s, the ID2 is the same for these items.


I want to propagate the indicated ID2 to all results in the same platform. Therefore, all rows in Platform 123 have Result of 531 and all rows in platform 321 have a result of 510.

 

My current dax is faulty:   
CALCULATE(MAX(ID2),
PLATFORM = EARLIER(PLATFORM),

INDICATOR = "X")

 

This does not propagate the correct result to all rows, only the rows that have an indicator. Any ideas?

 

PlatformID2IndicatorResult
123514 531
12354 531
123531X531
123  531
32115 510
321510X510
321510X510
3215 510
1 ACCEPTED SOLUTION
v-yiruan-msft
Community Support
Community Support

Hi @CarlsBerg999 ,

You can update the formula of your calculated column [Result] as below:

Result = 
CALCULATE (
    MAX ( 'Table'[ID2] ),
    FILTER (
        'Table',
        'Table'[Platform] = EARLIER ( 'Table'[Platform] )
            && 'Table'[Indicator] = "X"
    )
)

yingyinr_0-1643866942087.png

If the above one can't help you get the desired result, please provide more sample data(exclude sensitive data) and the correct result with backend logic and special examples. Thank you.

Best Regards

Community Support Team _ Rena
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

2 REPLIES 2
v-yiruan-msft
Community Support
Community Support

Hi @CarlsBerg999 ,

You can update the formula of your calculated column [Result] as below:

Result = 
CALCULATE (
    MAX ( 'Table'[ID2] ),
    FILTER (
        'Table',
        'Table'[Platform] = EARLIER ( 'Table'[Platform] )
            && 'Table'[Indicator] = "X"
    )
)

yingyinr_0-1643866942087.png

If the above one can't help you get the desired result, please provide more sample data(exclude sensitive data) and the correct result with backend logic and special examples. Thank you.

Best Regards

Community Support Team _ Rena
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Tahreem24
Super User
Super User

@CarlsBerg999 Try this DAX Column:

Column = CALCULATE(MAX(Table[ID2]),ALLEXCEPT(Table,Table[Platform]))
Capture.PNG
 
 
Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

Feb2025 NL Carousel

Fabric Community Update - February 2025

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

Top Kudoed Authors