Forum Discussion
Get Month Value in new column (another table) where Rank = 1
- Anonymous2 years ago
Hi ankurshah01 ,
Current you can't create dynamic calculated column or table based on filter effect, they works on different levels and you can't use the child level to effect its parent.
You can try to use the following measure formula if helps:
formula = VAR summary = SUMMARIZE ( ALLSELECTED ( Table1 ), [Calmonth], "Rank", [Rank1], "CalMonth", CALCULATE ( SUM ( table2[Volume] ), FILTER ( ALLSELECTED ( Table2 ), Table2[Calmonth] = [Calmonth] ) ) ) RETURN MAXX ( FILTER ( summary, [Rank] = 1 ), [CalMonth] )Notice: the data level of power bi(from parent to child level)
Database(external) -> query table(query, custom function, query parameters) -> data model table(table, calculate column/table) -> data view with virtual tables(measure, visual, filter, slicer)
Regards,
Xiaoxin Sheng
Hi ankurshah01 ,
Current you can't create dynamic calculated column or table based on filter effect, they works on different levels and you can't use the child level to effect its parent.
You can try to use the following measure formula if helps:
formula =
VAR summary =
SUMMARIZE (
ALLSELECTED ( Table1 ),
[Calmonth],
"Rank", [Rank1],
"CalMonth",
CALCULATE (
SUM ( table2[Volume] ),
FILTER ( ALLSELECTED ( Table2 ), Table2[Calmonth] = [Calmonth] )
)
)
RETURN
MAXX ( FILTER ( summary, [Rank] = 1 ), [CalMonth] )
Notice: the data level of power bi(from parent to child level)
Database(external) -> query table(query, custom function, query parameters) -> data model table(table, calculate column/table) -> data view with virtual tables(measure, visual, filter, slicer)
Regards,
Xiaoxin Sheng