Forum Discussion

luizzed's avatar
luizzed
Frequent Visitor
5 years ago
Solved

Conditional with DAX using columns from different tables

Hi! I have two tables: dimension fact with this relationship I'm trying to make a measure that when the value of the dimension[Value] column is empty, use the value of the fact...
  • smpa01's avatar
    5 years ago
    Measure = 
    IF (
        MAX ( dim[Value] ) = BLANK (),
        CALCULATE (
            MAXX ( FILTER ( 'fact', 'fact'[Index] = MAX ( dim[Index] ) ), 'fact'[Value] )
        ),
        MAX ( dim[Value] )
    )

    luizzed