The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Hi experts, I created a multiple dimension matrix, my solution is first created in dimension table and then use the switch true DAX get the revelent measure:
1.dimension table I created:
2.measure I created:
3.here is the result:
4. as can be seen above, the column name of year_name just come from dimen table and can not be changed, so how to get the dynamic column name based on slicer? for example, when selected FY24, then the column name of year_name keeps two value FY24, FY23, or 24,23
but the problem is that when selected the year, the year name is remained the same, so how to get the dynamic column name based on the slicer?
Solved! Go to Solution.
@Anonymous there's no way to change the column name dynamically. You can change it to a . so that 'year_name' doesn't display on your matrix. You can also use the 'Title' of the matrix or the 'subtitle' of the matrix (in the formatting for the matrix) to display the Years selected in your slicer.
To do that, click on the 'fx' in the title or subtitle formatting, then add a measure. Try a measue such as:
[fx Matrix Title selected Years] = CONCATENATEX ( VALUES( TableName[YearColumnNameUsedInSlicer] ), TableName[YearColumnNameUsedInSlicer] , ", " )
Copying DAX from this post? Click here for a hack to quickly replace it with your own table names
Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C
I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com
@Anonymous there's no way to change the column name dynamically. You can change it to a . so that 'year_name' doesn't display on your matrix. You can also use the 'Title' of the matrix or the 'subtitle' of the matrix (in the formatting for the matrix) to display the Years selected in your slicer.
To do that, click on the 'fx' in the title or subtitle formatting, then add a measure. Try a measue such as:
[fx Matrix Title selected Years] = CONCATENATEX ( VALUES( TableName[YearColumnNameUsedInSlicer] ), TableName[YearColumnNameUsedInSlicer] , ", " )
Copying DAX from this post? Click here for a hack to quickly replace it with your own table names
Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C
I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com
User | Count |
---|---|
69 | |
67 | |
62 | |
48 | |
28 |
User | Count |
---|---|
112 | |
81 | |
66 | |
54 | |
43 |