Forum Discussion
calculate formula
- 4 years ago
romovaro try this:
eenLights-Recount CUIDS = var tab = CALCULATETABLE ( VALUES ( 'BMPS LOF Report'[CID] ), 'BMPS LOF Report'[TASK] = "Greenlight Checks", 'BMPS LOF Report'[TASK_STATUS] = "Closed" ) return CALCULATE ( DISTINCTCOUNT( 'BMPS LOF Report'[CUID] ), INTERSECT ( VALUES('BMPS LOF Report'[CID] ), tab ), NOT ISBLANK ( 'BMPS LOF Report'[CUID] ) )✨ Follow us on LinkedIn and to our YouTube channel
Learn about conditional formatting at Microsoft Reactor
My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.
romovaro I think I have a video on a similar task, check it here https://youtu.be/zS1IDl3DLak
✨ Follow us on LinkedIn and to our YouTube channel
Learn about conditional formatting at Microsoft Reactor
My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.
- romovaro4 years ago
Responsive Resident
HI Parry
Video looks good. Facing some problems but I will check again. In the meantime i updated the formula to get the Total Counts of CUIDs:
reenLights-Recount CUIDS =var tab =CALCULATETABLE (VALUES ( 'BMPS LOF Report'[CID] ),FILTER ('BMPS LOF Report','BMPS LOF Report'[TASK] = "Greenlight Checks"&& 'BMPS LOF Report'[TASK_STATUS] = "Closed"))returnCALCULATE (DISTINCTCOUNT( 'BMPS LOF Report'[CUID] ),INTERSECT ( VALUES('BMPS LOF Report'[CID] ), tab ))But the formula counts the "Blank Space" as a distinccount...and it's wrong. Null should not be in the total count.CUID 380305CA01 BLANK 380305AE01 380305SA01 380305BH01 380305TW01 380305JP01 380305KR01 380305MY01 380305MX01 380305SG01 380305SG02