Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Measure with relationship blows up table visual

Hi.   I'm trying to wrap my head around this one with no success. Hope someone can help me understand what is happening here   I'm using direct query to postgres. I have two tables; order and ord...
  • v-xuding-msft's avatar
    6 years ago

    Hi Anonymous ,

    It is caused by the row context where the measure "HasSpecialRows" is. When put it into the "order" table, it will show based on order(id).

    You could try to create a calculated column as Daviejoe suggested. Or you could try the formula below to create a new measure.

    Measure = 
    IF (
        MAX ( 'order'[id] ) = MAX ( orderrow[order_id] )
            && MAX ( 'order'[id] ) <> BLANK (),
        IF ( SUM ( orderrow[IsSpecialRow] ) > 0, "True", "False" )
    )

    Best Regards,

    Xue Ding

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.