Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
I'm trying to calculate the number of sessions in my data. Sessions = a unique combination of Day + Cluster + User.
My data resembles this:
Date | Cluster | User |
Nov 1 | 111 | AAA |
Nov 2 | 222 | AAA |
Nov 2 | 333 | BBB |
Nov 2 | 333 | BBB |
Nov 3 | 444 | CCC |
Nov 3 | 333 | AAA |
In the above example, I want a calculation that results in this:
Ultimately, I want to know how many sessions per day, which I'd show in a table or chart.
Any help is appreciated.
Solved! Go to Solution.
Hi @rlongden ,
You may create a calculated column to concatenate those fields if you have other fields in your table:
UniqueID =
Table[Date] & Table[Cluster] & Table[User]
Then create a measure to count the distinct values:
Unique Count =
DISTINCTCOUNT ( Table[UniqueID] )
Proud to be a Super User!
Hi @rlongden ,
You may create a calculated column to concatenate those fields if you have other fields in your table:
UniqueID =
Table[Date] & Table[Cluster] & Table[User]
Then create a measure to count the distinct values:
Unique Count =
DISTINCTCOUNT ( Table[UniqueID] )
Proud to be a Super User!
Thanks to both of you. This gives me what I need. To danextian, you guessed right that my actual data has some other columns that I didn't want in the calculation. I was able to use your example to get it working.
Hi,
Drag Date to the Table visual. This measure works
Measure = COUNTROWS(DISTINCT(Data))
User | Count |
---|---|
126 | |
108 | |
99 | |
65 | |
62 |
User | Count |
---|---|
137 | |
116 | |
102 | |
71 | |
61 |