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
drive007
Frequent Visitor

Count Cross Device User

Hey all experts,

 

I am stucked with the following problem:

 

I have one table with login entries of users with the following columns

Date - userid - logintype

 

We have two login types:

1 - desktop

2 - app

 

I can easily calculate how many people logged in per month via app or desktop, however I dont know how to count the number of users who have logged in with both (so have table entries with logintype=1 AND another entry with logintype=2).

 

I would like to calculate:

How many users are cross device users per day (logintype =1 AND logintype=2)

How many users are cross device users per week (logintype =1 AND logintype=2)

How many users are cross device users per month (logintype =1 AND logintype=2)

 

I thought I need to create some kind of calculated / Summarized table for this. But unfortunately it did not work. Not sure whether there is an easy workaround I missed.

 

I appreciate your help

 

Cheers

Jörg

1 ACCEPTED SOLUTION
v-cherch-msft
Employee
Employee

Hi @drive007

 

You may try to add 2 columns for your table. One is Month column and the other is ‘Week of Month’ column as below picture. You may go to Query Editor->Add Column->Date to get ‘Week of Month’ column. Then you may try to create a measure as below:

 

Measure =
VAR a =
    SUMMARIZE ( Table1, Table1[userid], "a1", DISTINCTCOUNT ( Table1[logintype] ) )
RETURN
CALCULATE ( DISTINCTCOUNT ( Table1[userid] ), FILTER ( a, [a1] = 2 ) )

 a.jpg1.png

 

Regards,

Cherie

 

 

Community Support Team _ Cherie Chen
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

2 REPLIES 2
v-cherch-msft
Employee
Employee

Hi @drive007

 

You may try to add 2 columns for your table. One is Month column and the other is ‘Week of Month’ column as below picture. You may go to Query Editor->Add Column->Date to get ‘Week of Month’ column. Then you may try to create a measure as below:

 

Measure =
VAR a =
    SUMMARIZE ( Table1, Table1[userid], "a1", DISTINCTCOUNT ( Table1[logintype] ) )
RETURN
CALCULATE ( DISTINCTCOUNT ( Table1[userid] ), FILTER ( a, [a1] = 2 ) )

 a.jpg1.png

 

Regards,

Cherie

 

 

Community Support Team _ Cherie Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Cheers. It worked fine. Thanks a lot!

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.