cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
manish_tripathi
Frequent Visitor

Active users on a given date in a Month

I am working to get cumulative distinct count of uids on daily basis. My dataset consists dates and UserIDs active on that date. Example : Say there are 2 uids (235,2354) appeared on date 2022-01-01 and they also appeared on next day with new uid 125 (235,2354,125) on 2022-01-02 At this point i want store cumulative count to be 3 not 5 as (user id 235 and 2354 already appeared on past day ).

 

My Sample Data looks like as follows

DateUser ID
1-Jan123
1-Jan234
1-Jan123
1-Jan234
1-Jan456
1-Jan564
1-Jan5644
1-Jan235
1-Jan2354
2-Jan235
2-Jan2354
2-Jan125
2-Jan1264
2-Jan564
2-Jan897
2-Jan987
3-Jan123
3-Jan321
3-Jan1265
3-Jan1256
3-Jan1553
3-Jan654
3-Jan9875
3-Jan5647
3-Jan6542
4-Jan321
4-Jan124
4-Jan1256
4-Jan325
4-Jan987
4-Jan568
4-Jan2589
4-Jan6547
4-Jan3321
4-Jan458
4-Jan123
4-Jan1264
4-Jan821
4-Jan542
4-Jan123
4-Jan1264
4-Jan821
4-Jan542

 

I am expecting following output

 

 DAU
Daily_Cumulative_Count
1-Jan77
2-Jan711
3-Jan919
4-Jan1428
2 ACCEPTED SOLUTIONS
m_alireza
Solution Specialist
Solution Specialist

Hi @manish_tripathi ,

Try this measure

Daily_Cumulative_Count = CALCULATE(DISTINCTCOUNT('Table'[User ID]),FILTER(ALL('Table'),'Table'[Date]<=MAX('Table'[Date])))

View solution in original post

Ashish_Mathur
Super User
Super User

Hi,

You may download my PBI file from here.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

5 REPLIES 5
Ashish_Mathur
Super User
Super User

Hi,

You may download my PBI file from here.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Thank you by replacing all with allselected it worked like a charm

You are welcome.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
m_alireza
Solution Specialist
Solution Specialist

Hi @manish_tripathi ,

Try this measure

Daily_Cumulative_Count = CALCULATE(DISTINCTCOUNT('Table'[User ID]),FILTER(ALL('Table'),'Table'[Date]<=MAX('Table'[Date])))

Thank you now i have two ways to solve the problem. Thank you for your help

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors