The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
I have a matrix with a double header. The first one, is divided between actual year and last year. The second one, is for the measures, such as [Sales] and [Sales LY] (I have more measures, some should only appear under Actual, this is a simplification). Thus, one measure should be under Actual, and the other one under Last Year.
However, both columns are repeated under both header sections, one with data and the other one blank. After researching the web, I have tried the solution of "Show items with no data" on the column section, but I think it is not intended for my particular case. I also tried to create a measure filtering only the columns with data, but I am not sure I did it well or if it can work. It is as follows:
Col Filter = CALCULATE( SUM(Fact_Sales[Sales]), ALLEXCEPT(Fact_Sales, Fact_Sales[Measure]))
My fact tables have a column [Measure], specifying the nature of the data (created in power bi in order to get the two header matrix). I have one table Fact_Sales, and another table Fact_Sales_LastYear, also in order to add the column Measure that would give each line the characteristic "Actual Year" or "Last Year".
The actual shape is:
And the intended result is to exclude the two empty columns.
Thanks in advance.
Hi @çq ,
I'd like to suggest you remove the column category and directly use these two measure expression on value, then they should disable on the correspond filed without any repeating.
If the above not help, can you please share a pbix or some dummy data that keep the raw data structure with expected results? It should help us clarify your scenario and test to coding formula.
How to Get Your Question Answered Quickly
Regards,
Xiaoxin Sheng