Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and a 50 percent discount on exams.
Get startedEarn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hi Guys.
Looking for some help with measures/calculated columns.
Goal is to come up with a calculation that identifies whether:
From above example, Emp2 had both grade and salary change in Feb-22, but then again, changed salary in Mar-222 but grade remained the same. Emp3 had changes all the 3 months.
Solved! Go to Solution.
@azakir , With help from a date Table
This Month Grade= CALCULATE(Max(Table[Grade]),DATESMTD('Date'[Date]))
Last Month Grade= CALCULATE(Max(Table[Grade]),DATESMTD(dateadd('Date'[Date],-1,MONTH)))
This Month Salary= CALCULATE(Max(Table[Salary]),DATESMTD('Date'[Date]))
Last Month Salary= CALCULATE(Max(Table[Salary]),DATESMTD(dateadd('Date'[Date],-1,MONTH)))
now create measures like
Changed grade
countx(values(Table[Employee]), if(not(isblank([This Month Grade])) && not(isblank([Last Month Grade])) && [This Month Grade] <> [Last Month Grade], [Employee], blank()))
Do same for salary
A modified approch above, what I discussed in this blog
@azakir , With help from a date Table
This Month Grade= CALCULATE(Max(Table[Grade]),DATESMTD('Date'[Date]))
Last Month Grade= CALCULATE(Max(Table[Grade]),DATESMTD(dateadd('Date'[Date],-1,MONTH)))
This Month Salary= CALCULATE(Max(Table[Salary]),DATESMTD('Date'[Date]))
Last Month Salary= CALCULATE(Max(Table[Salary]),DATESMTD(dateadd('Date'[Date],-1,MONTH)))
now create measures like
Changed grade
countx(values(Table[Employee]), if(not(isblank([This Month Grade])) && not(isblank([Last Month Grade])) && [This Month Grade] <> [Last Month Grade], [Employee], blank()))
Do same for salary
A modified approch above, what I discussed in this blog
Hi @amitchandak . Thanks for your help mate. This worked a charm. Double Kudos to you if I had the oppurtunity 🙂
User | Count |
---|---|
92 | |
86 | |
78 | |
72 | |
65 |
User | Count |
---|---|
115 | |
107 | |
85 | |
65 | |
64 |