March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi guys,
I am trying to see if employees are sick, on holiday or available at the office.
To do this I created two columns with "Status description" to determine if they are available or not
Column 1:
Column 2:
So, what takes precedence? If one column shows Available and one Away, which is it and what is it for all possible combinations of values?
@Greg_Deckler If they are either sick or on holiday they should be away.
So it should look something like:
Measure x = IF('AbsenceRegistrationTransaction'[StatusDescription] = "Away" ; "Away"; IF('LeaveRegistration'[StatusDescription] = "Away"; "Away"; "Available"))
Really hard to do this one without sample data or more specifics around what you want this to end up like. But, let's say you have a data slicer that you filter down to a specific date. And you have a table visual of employees, you might be able to do a measure like:
Measure =
VAR __EmployeeID = MAX('Employees'[EmployeeID])
VAR __Date = SELECTEDVALUE('Dates'[Date])
VAR __LeaveStatus1 = MAXX(FILTER('LeaveTable1',[EmployeeID] = __EmployeeID && [Date] = __Date),[LeaveStatus1])
VAR __LeaveStatus2 = MAXX(FILTER('LeaveTable2',[EmployeeID] = __EmployeeID && [Date] = __Date),[LeaveStatus2])
RETURN
<Implement your business logic here>
@Greg_DecklerThanks for helping me so far, but if I try your measure it will only return "Away" for one employee, not for the others.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
124 | |
87 | |
87 | |
70 | |
51 |
User | Count |
---|---|
205 | |
153 | |
97 | |
79 | |
69 |