Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.

Reply
jaweher899
Impactful Individual
Impactful Individual

dynamic columns in table

I've the following pbix file https://1drv.ms/u/s!Amd7BXzYs7AVk3D5iDMIrhfnpQNW?e=lHWRuH

when the user select in colun name %var, it'll add the measure %var n the table and only when both intial.subtotal and table1.Initial subtotal are selected.

 

 

jaweher899_0-1671726676598.png

 

 

for example here when initial.subtotal is not selected and %var is selected, so %var will not be added to the table

jaweher899_1-1671726676510.png

 

In case of I select var and % var , both measures should be displayed.

In case of I select nothing for the slicer column name,var and %var should not be dispalyed.

 

I try to find a solution since two weeks, if someone can help me, it'll be much appreciated.

1 ACCEPTED SOLUTION

https://we.tl/t-SQ3FDr0b9l





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

13 REPLIES 13
bolfri
Solution Sage
Solution Sage

This is what you want?

User picksShow in the table
%var%var
%varInitial Subtotal
%varTable1.Initial Subtotal
%var & varvar
%var & var%var
Nothing 

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




jaweher899
Impactful Individual
Impactful Individual

  • Thank you for your reply @bolfri.When the user select %var, he should choose both initial subtotal and table1. Initial subtotal in order to show three measures initial subtotal and table1. Initialnsubtotal and %var.
  • If the user chooses %var and only initial subtotal, so in the table i need to show only initial subtotal

Hope that I'm clear, thank you

The problem here is that you're expecting from end user that he nows the correct combinations of filters. It's easier to provide him a correct options right now.

 

Subtotal 1 = SUM(FactSales[Initial Subtotal])
Subtotal 2 = SUM(FactSales[table1.Initial Subtotal])
Difference = [Subtotal 1] - [Subtotal 2]
% Difference = DIVIDE([Difference],[Subtotal 2])
 
Possible solution: Can you accept something like this?
 
bolfri_0-1671733208812.pngbolfri_1-1671733264962.pngbolfri_2-1671733277960.pngbolfri_3-1671733288754.pngbolfri_4-1671733297543.pngbolfri_5-1671733306968.png

 

 

 

 

 

 

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




jaweher899
Impactful Individual
Impactful Individual

Thank you again @bolfri, the issue is that in the real report I've around 80 measures, and for each two measures i need to calculate the variance and %of variance, so it'll too much measures..

The user expects to have separately a slicer variance and cov to click on it, then it will display variance for only the measures selected. 

(+kudo) 

This is totally different logic then and issue that you didn't mention.

So you have like 80 values that can be measured and you want to user to pick 2 od them to compare and then decide if to show the difference (# and %), right?





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




jaweher899
Impactful Individual
Impactful Individual

@bolfri yes, In the sample I put only two measures to simplify my issue

My answer was based on the sample data and description that you've provided. And your question didn't include such problem as choosing different measures to compare. 🙂 I think you should put more measures and discribe this problem one more time, so it will be easier for everyone to find it in the future.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




jaweher899
Impactful Individual
Impactful Individual

hi @bolfri I put a new question, hope that I'm clearer.

@bolfri @could you please share thr pbix file and I'll check it? Thank you

https://we.tl/t-SQ3FDr0b9l





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




jaweher899
Impactful Individual
Impactful Individual

Thank you @bolfri, you're brilliant!

TomMartens
Super User
Super User

Hey @jaweher899 ,

 

it's simply not possible to show a column based on conditions.

The only thing that is close is the field parameters feature: Let report readers use field parameters to change visuals (preview) - Power BI | Microsoft Learn

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

@TomMartens thank you for your reply. I alredy use field parameter in the table in the pbix file. Could you please show how to use another field parameter in the same table? 

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.