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.
Hello Team,
Im creating a measure "GET_LIEN_STR_SA" it needs max date and conditions on few types and status. when I use MAX its just giving maximum date in that particular column keeping all other blank. I want max date for each record of account id .
Thanks in advance.
Solved! Go to Solution.
Hi @PavaniD
Can you please try DAX like the below (example only), please update the filter condition as per the requirement
CALCULATE(
MAX('Table'[DateColumn]),
FILTER(
'Table',
'Table'[AccountID] = EARLIER('YourTable'[AccountID]) &&
'Table'[Type] IN {"Type1", "Type2"} &&
'Table'[Status] = "YourStatus"
)
)
Let me know if that works for you
If your requirement is solved, please mark THIS ANSWER as SOLUTION ✔️ and help other users find the solution quickly. Please hit the LIKE 👍 button if this comment helps you.
Thanks
Pijush
Linkedin
Hi @PavaniD
I ran the testing as follows.
My sample:
Measure:
GET_LIEN_STR_SA = CALCULATE(MAX([Date]), ALLEXCEPT('Table', 'Table'[ID], 'Table'[status]))
Is this the result you expect?
If I've misunderstood you, please provide detailed sample data and the results you are hoping for: How to provide sample data in the Power BI Forum - Microsoft Fabric Community . Or show it as a screenshot or pbix. Please remove any sensitive data in advance. If uploading pbix files please do not log into your account.
Best Regards,
Yulia Xu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @PavaniD
I ran the testing as follows.
My sample:
Measure:
GET_LIEN_STR_SA = CALCULATE(MAX([Date]), ALLEXCEPT('Table', 'Table'[ID], 'Table'[status]))
Is this the result you expect?
If I've misunderstood you, please provide detailed sample data and the results you are hoping for: How to provide sample data in the Power BI Forum - Microsoft Fabric Community . Or show it as a screenshot or pbix. Please remove any sensitive data in advance. If uploading pbix files please do not log into your account.
Best Regards,
Yulia Xu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @PavaniD
Can you please try DAX like the below (example only), please update the filter condition as per the requirement
CALCULATE(
MAX('Table'[DateColumn]),
FILTER(
'Table',
'Table'[AccountID] = EARLIER('YourTable'[AccountID]) &&
'Table'[Type] IN {"Type1", "Type2"} &&
'Table'[Status] = "YourStatus"
)
)
Let me know if that works for you
If your requirement is solved, please mark THIS ANSWER as SOLUTION ✔️ and help other users find the solution quickly. Please hit the LIKE 👍 button if this comment helps you.
Thanks
Pijush
Linkedin
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 |
---|---|
105 | |
101 | |
79 | |
72 | |
64 |
User | Count |
---|---|
141 | |
107 | |
100 | |
82 | |
74 |