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
Anonymous
Not applicable

Apply data segmentation to an acumulated count

Hi,

I am trying to apply a data segmentation through  a visual object that respects this DAX filter

 

Acumulated s/d = calculate(count('Checkin-Chekout'[Tipe]),

filter(all('Checkin-Chekout'),

'Checkin-Chekout'[Date .] <= max('Checkin-Chekout'[Date .])))
This DAX counts counts check in / check out and aplies a filter that acumulate them by date.
The problem is that when I use de visual objet of segmentation with 'Checkin-Chekout'[Hotel] column , it dosen't show the acumulated count of that hotel by date and that's what I want.
Can anyone help me?
Thanks a lot.
1 ACCEPTED SOLUTION
V-lianl-msft
Community Support
Community Support

Hi @Anonymous ,

 

You can create a new column to count each row then create cumulative total measure.

count_row = 1

Measure = CALCULATE(SUM('Table'[count]),FILTER(ALL('Table'[List Date]),'Table'[List Date]<=MAX('Table'[List Date])))

test_count_runningtotal.PNG

Sample .pbix 

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
V-lianl-msft
Community Support
Community Support

Hi @Anonymous ,

 

You can create a new column to count each row then create cumulative total measure.

count_row = 1

Measure = CALCULATE(SUM('Table'[count]),FILTER(ALL('Table'[List Date]),'Table'[List Date]<=MAX('Table'[List Date])))

test_count_runningtotal.PNG

Sample .pbix 

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

You solved it! thank you very much, it was that simple and i couldn't see it.

amitchandak
Super User
Super User

@Anonymous 

Did not get it completely. But it better to move you Date to date table and have that filter there

S/d acumulado á calculate([Tipe],
filter(all('Date'),
'Date'[Fecha .] <max('Date'[Fecha .])))

 

To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :
https://radacad.com/creating-calendar-table-in-power-bi-using-dax-functions
https://www.archerpoint.com/blog/Posts/creating-date-table-power-bi
https://www.sqlbi.com/articles/creating-a-simple-date-table-in-dax/

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.