0
votes

Average date between two dates in Power BI using DAX not working.

Is there a way to solve this using DAX? Average days between Registration Date and Start Date (For all user IDs the difference between Start Date minus Registration Date. enter image description here

1
Can you share some sample data? What you have tried so far? - Angelo Canepa
Please check my edited formula - Alan K

1 Answers

0
votes

I would use a measure that takes the difference between the two dates, divides it by 2 and then adds the result to the start date:

DATEADD(
    LASTDATE([Start Date]),
    DATEDIFF(
        LASTDATE([Start Date]),
        LASTDATE([Registration Date]),
        DAY
    )/2,
    DAY
)

EDIT: Changed MAX to LASTDATE.