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,
I have two columns effective from and current position. i want to compute a colum of duration which will let us know the duration of a person designation. for example the duration of "assistant manager" will be 2 year and duration of "head" will be 8 years and 2 months. how can we find it through DAX.
Thnaks in advance
Solved! Go to Solution.
Hi @HassanAli123 ,
Whether the advice given by @truptis @mh2587 has solved your confusion, if the problem has been solved you can mark the reply for the standard answer to help the other members find it more quickly. If not, please point it out.
Looking forward to your feedback.
Best Regards,
Henry
actually i didn't try these solutions. I posted this question again and @amitchandak solved my problem.
Hi @HassanAli123 ,
Can you provide a link to the solution here? Looking forward to your reply.
Best Regards,
Henry
Did I answer your question? If so, please mark my post as a solution!
Proud to be a Super User!
Hi @HassanAli123 ,
You can use DATEDIFF function here.
Eg - Result_for_years = DATEDIFF(effective_form, Today(), Year)
(for first row, this will return no. of years between 01/01/2012 to today's date)
Result_for_months = DATEDIFF(effective_form, Today(), Month)
(for first row, this will return no. of months between 01/01/2012 to today's date)
Result_for_days = DATEDIFF(effective_form, Today(), Day)
(for first row, this will return no. of days between 01/01/2012 to today's date)
@HassanAli123 -> Please mark this as a solution if it helps you. Thank you.
Regards,
TruptiS
actually you did not get my point. the person is same in both designation. i want to calculate duration separately for assistant manager it should calculate till 2014 mean 2 years and 8 year 2 months for head roll
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 |
---|---|
123 | |
85 | |
85 | |
70 | |
51 |
User | Count |
---|---|
205 | |
153 | |
97 | |
79 | |
69 |