The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
I have the measures. In the PR_SPL_DATE_CHANGED measure, the filter is returning null records of LEFT(Products[RUN_DATE],4) along with the matching records. I expect this should return only for (Products[RUN_DATE],4) = LEFT([MIN_RUN_DATE],4) condition whereas the null records also being filtered out from this. I dont know what is the reason behind this.
MIN_RUN_DATE = CALCULATE(MIN(Products[RUN_DATE]), LEFT(Products[RUN_DATE],4) = FORMAT(YEAR(TODAY()),BLANK()))
PR_SPL_DATE_CHANGED = IF((CALCULATE(COUNTROWS(VALUES(Products[PR_SPL_SALES_DATE])),
FILTER(Products, LEFT(Products[RUN_DATE],4) = LEFT([MIN_RUN_DATE],4)))) = 1,0,1)
Hi @Anonymous ,
Here I create a sample file to have a test.
Your code works well on myside.
Here I have some questions. I am confused that whether [RUN_DATE] and [PR_SPL_SALES_DATE] are text data format.
I think your calculation is based on your data model, please share a sample file with me and show me a sceenshot with the result you want. This will make it easier for me to find the solution.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the August 2024 Power BI update to learn about new features.
User | Count |
---|---|
12 | |
2 | |
1 | |
1 | |
1 |