The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello, good afternoon.
I'm looking at how to put together a measure to calculate the number of collaborators scheduled for a time slot. For this, I have a table with 30-minute intervals, from 00:00 to 23:30, and another table with the schedule of each collaborator, which includes date, time of entry and time of departure.
In Excel I do it with a count.ifset, but I can't figure out how to do it with DAX. Will you be able to guide me?
Thanks a lot.
@Syndicate_Admin , I first table have two columns start time and end time.
Then you can populate a bucket column in second table and use that in join
New column in table 2
maxx(filter(Table1, Table2[Time] >= Table1[Start Time] && Table2[Time] <= Table[End Time]), Table1[Time bucket])
refer 4 ways (related, relatedtable, lookupvalue, sumx/minx/maxx with filter) to copy data from one table to another
https://www.youtube.com/watch?v=Wu1mWxR23jU
https://www.youtube.com/watch?v=czNHt7UXIe8
User | Count |
---|---|
78 | |
73 | |
38 | |
30 | |
28 |
User | Count |
---|---|
107 | |
100 | |
55 | |
49 | |
45 |