Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for a $400 discount.
Register nowGet inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.
Hi,
I'm working in an Excel Pivot table, and I have a disconnect table: TopN value.
My model:
In the disconnected table I have the following measure: TopN_Value= =SELECTEDVALUE('topN'[TopN value])
In the following filter context everything is ok:
But when I drag the TopN_Value measure to the table, it ignore the filter context, and list all the row values for "TARIFA". I think this not happen in Power Bi.
Thanks,
Paulo Praça
Hi @ppraca As I can understand that, you want to sum the top N value as chosen by the user from the disconnected table. If this is the case, you have to integrate selected value of TopN to your sum measure. Create sum measure to solve the problem :
SumConsumo =
VAR TopN_Value = SelectedValue(TopN[TopN_Value])
VAR _Result = Sumx(TOPN(TopN_Value, YourTable, [Value]), [Value])
Return
_Result
This measure will first select top N value as chosen by the user from the disconnected table, and then sum up the corresponding values. Please adjust the table and column names accordingly.
Hope this helps!!
If this solved your problem, please mark it as a solution!!
@ppraca ,You might need to use the CALCULATE function to modify the filter context explicitly.
Proud to be a Super User! |
|
Thanks for your answer, but doesn't work.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code FABINSIDER for a $400 discount!
Check out the February 2025 Power BI update to learn about new features.
User | Count |
---|---|
19 | |
14 | |
10 | |
9 | |
9 |
User | Count |
---|---|
15 | |
12 | |
12 | |
11 | |
11 |