Forum Discussion
MKeppel
4 years agoFrequent Visitor
Counting Events in Times Slots
I am looking for a way (correct measure formular) to count events in times slots, which include events when spans over a single 1 hour period..
Also should there be a time dimention table which is just 0-23 ? (well more likely 7 - 20 since no classes outside of the time)
| Start | Duration | Day | Name | End Time |
| 9 | 1 | Monday | Class A | 10 |
| 11 | 1 | Monday | Class B | 12 |
| 8 | 3 | Monday | Class C | 11 |
| 10 | 2 | Monday | Class D | 12 |
Expected Results
| Time\Day | Monday |
| 8 | 1 |
| 9 | 2 |
| 10 | 2 |
| 11 | 2 |
| 12 | 0 |
| 13 | 0 |
2 Replies
- amitchandakSuper User
MKeppel , Create table using generateseries
Time = generateseries (1,24,1)
then join it with start
Create measure like
count(Table[Day])+0
- MKeppelFrequent Visitor
That will not achieve what I am after.
If a booking goes over two houes, I want it to count +1 for each hour it is in.
So I will need it to filter the counting row if the Time >= starttime & < endtime.