Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi Newbie here in Dax formula,
what formula should i use if this is the outcome that i want to see ( expected Result, i want to get the oldest date). Thank you so much for the help
ProfileId | Final Submission Date | DistinctProfileDate | expected Result | |
187475 | 10/03/2023 | 187475-3/10/2023 | 187475-3/10/2023 | |
187475 | 10/03/2023 | 187475-3/10/2023 | 187475-3/10/2023 | |
187475 | 27/03/2023 | 187475-3/27/2023 | blank | |
187475 | 27/03/2023 | 187475-3/27/2023 | blank | |
187475 | 27/03/2023 | 187475-3/27/2023 | blank | |
187475 | 01/04/2023 | 187475-4/1/2023 | blank | |
187475 | 01/04/2023 | 187475-4/1/2023 | blank | |
187475 | 01/04/2023 | 187475-4/1/2023 | blank | |
187475 | 01/04/2023 | 187475-4/1/2023 | blank | |
187475 | 01/04/2023 | 187475-4/1/2023 | blank | |
187475 | 01/04/2023 | 187475-4/1/2023 | blank | |
187475 | 01/04/2023 | 187475-4/1/2023 | blank | |
187475 | 24/04/2023 | 187475-4/24/2023 | blank | |
187475 | 24/04/2023 | 187475-4/24/2023 | blank | |
187475 | 27/04/2023 | 187475-4/27/2023 | blank | |
187475 | 27/04/2023 | 187475-4/27/2023 | blank | |
187475 | 27/04/2023 | 187475-4/27/2023 | blank | |
187475 | 28/03/2023 | 187475-3/28/2023 | blank |
Exprected Column Result =
IF ( 'Table'[ProfileId] = MIN('Table'[ProfileId])
&& 'Table'[Final Submission Date] = CALCULATE(Min('Table'[Final Submission Date]), Filter('Table', 'Table'[ProfileId] = MIN('Table'[ProfileId])
&& 'Table'[Final Submission Date] <= EARLIEST('Table'[Final Submission Date])))
, 'Table'[DistinctProfileDate], blank()
)
Column DAX code
@jhoyabel19 As a column:
expected Result column =
VAR __ProfileId = [ProfileId]
VAR __MinDate = MINX(FILTER('Table', [ProfileId] = __ProfileId), [Final Submission Date])
VAR __Result = MINX(FILTER('Table', [ProfileId] = __ProfileId && [Final Submission Date] = __MinDate), [DistinctProfileDate])
RETURN
__Result
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
95 | |
80 | |
68 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |