Forum Discussion
Fill down all matched value same year
- Anonymous2 years ago
Hi hoangDAO81 ,
Is it necessary to compare [ENERGY CONSUMPTION BY] under the same ID? If so, try this measure:Energy consumption BY = VAR _base_year = SELECTEDVALUE('Total E'[Baseyear]) VAR _result = CALCULATE([Energy comsumption], 'Total E'[Year]=_base_year) RETURN _resultBest Regards,
Gao
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group
Hi hoangDAO81 ,
Is it necessary to compare [ENERGY CONSUMPTION BY] under the same ID? If so, try this measure:
Energy consumption BY =
VAR _base_year = SELECTEDVALUE('Total E'[Baseyear])
VAR _result = CALCULATE([Energy comsumption], 'Total E'[Year]=_base_year)
RETURN
_result
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group
Dear Gao,
This is close with what i need but the values are not show as your table, they only show year 2018, can you refine some of your DAX. Thank you!
- Anonymous2 years agoNot applicable
Hi hoangDAO81 ,
Both [ID] and [Year] fields need to be placed in the table visual.Grouping by year only will result in multiple Base Years corresponding to Years. Or is there some other unspecified calculation logic?
Best Regards,
Gao
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group