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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Petazo
Helper I
Helper I

Matrix with several colulmans

Hello everyone

I have a problem that is simple, but I haven't been able to fix

I have the following measure

medida.PNG

What this measure does is count the first line according to the periodo_dias, the last day of the dashboard context. everything's fine here and gives the calculation I need.

tabla con cuenta total.PNG

The test gives when I add columns to the matrix, since the count a makes the inside of cda column, leaving incongruous the total sum

tabla con problema.PNG

COmo is expected to see, in the first row count 1 for business, 8 for support, given total 8, intuitively one says it is 9, but in reality it is 8 the value that is expected. When reviewing in detail the row with id 4885 is being counted in both columns, when reviewing the detail from which the lines are counted I see that it is effectively in the lists of rework and validation of retail, in this way counting the last date of both columns, but that when totalizing only the last of both.

What is needed is that you only count the last indistinct of whether you were in any of the previous stages (client, business or support). try a filter all to the extent, but I think I misused it.

I hope you can help me.

Best regards.

1 ACCEPTED SOLUTION
Petazo
Helper I
Helper I

Dear:

I was able to solve the problem, I leave the solutions in case anyone needs it in the future.

In the original measure the last filter of the Calculate is the lastday of the table where I have the transactions. That date field is attached to the data model calendar.

So instead of filtering the date in the data table, it made any segmentation do the calculations within and each segmentation. To have the last day of the total I changed the lastday with the calendar date (this has no union with the attribute tables) so I did the calculation well.

medida_arreglada.PNG

tabla sin problema.PNG

Please consider it resolved!

Thank you, Greetings.

View solution in original post

2 REPLIES 2
Petazo
Helper I
Helper I

Dear:

I was able to solve the problem, I leave the solutions in case anyone needs it in the future.

In the original measure the last filter of the Calculate is the lastday of the table where I have the transactions. That date field is attached to the data model calendar.

So instead of filtering the date in the data table, it made any segmentation do the calculations within and each segmentation. To have the last day of the total I changed the lastday with the calendar date (this has no union with the attribute tables) so I did the calculation well.

medida_arreglada.PNG

tabla sin problema.PNG

Please consider it resolved!

Thank you, Greetings.

@Petazo , Thanks for sharing the solutions. Kudo's to you.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.