Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more.
Get startedGrow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.
Hi All,
I have a table with 1 column having employee ID, another having dates, and a third column having punch in and punch out time of each employee for each date. Assuming, every employee can have multiple in and out timings for a day. I want a column in which the minimum time for each date per employee to be the "InTime" and the maximum time for each date per employee to be the "OutTime". The time punches in between should alternate between "In" and "Out" based on the measure "count rows". If the measure is odd, the last two values must be "Out" and if measure is even, alternate values should be there. This is to be achieved in Power BI Hoping for some help. Thanks in advance!
Solved! Go to Solution.
@kanikasharma123 , Make sure you have date column first
Date = Datevalue([punch in])
New columns
Min Punch in = minx(filter(Table, [Emp] = earlier([Emp]) && [Date] = earlier([Date]) ), [punch in])
Max Punch out = Maxx(filter(Table, [Emp] = earlier([Emp]) && [Date] = earlier([Date]) ), [punch out])
@kanikasharma123 , Make sure you have date column first
Date = Datevalue([punch in])
New columns
Min Punch in = minx(filter(Table, [Emp] = earlier([Emp]) && [Date] = earlier([Date]) ), [punch in])
Max Punch out = Maxx(filter(Table, [Emp] = earlier([Emp]) && [Date] = earlier([Date]) ), [punch out])
User | Count |
---|---|
88 | |
72 | |
69 | |
65 | |
57 |
User | Count |
---|---|
95 | |
93 | |
91 | |
75 | |
69 |