Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi,
I have 2 tables Incident and Project where incidentID column is the commom column from both the tables.
Incident table has statuses ( Rejected and approved)
Project table has statuses ( Not Started and In Progress)
now i need to create a measure like - get the count of incidents with status = Rejected from incidents and count of incidents in project with status in Not Started and In Progres.
condition is - we need to get the count for theincidents whose status is rejected and for the same incidents in project with status Not Started and In Progres.
Measure = Rejected & Not Started & In Progres
Need help ASAP.
Solved! Go to Solution.
HI @hemanth2018,
You can try to use below formula if it works for your scenario.
Measure = VAR idList = CALCULATE ( VALUES ( Incident[incidentID] ), FILTER ( ALLSELECTED ( Incident ), Incident[statuses] = "Rejected" ), VALUES ( Incident[incidentID] ) ) RETURN CALCULATE ( COUNT ( Product[incidentID] ), FILTER ( ALL ( Project ), Project[incidentID] IN idList && Project[statuses] IN { "Not Started", "In Progres" } ) )
If above not help, please share same sample data for test and coding formula.
Regards,
Xiaoxin Sheng
HI @hemanth2018,
You can try to use below formula if it works for your scenario.
Measure = VAR idList = CALCULATE ( VALUES ( Incident[incidentID] ), FILTER ( ALLSELECTED ( Incident ), Incident[statuses] = "Rejected" ), VALUES ( Incident[incidentID] ) ) RETURN CALCULATE ( COUNT ( Product[incidentID] ), FILTER ( ALL ( Project ), Project[incidentID] IN idList && Project[statuses] IN { "Not Started", "In Progres" } ) )
If above not help, please share same sample data for test and coding formula.
Regards,
Xiaoxin Sheng
User | Count |
---|---|
77 | |
74 | |
42 | |
32 | |
28 |
User | Count |
---|---|
99 | |
92 | |
50 | |
49 | |
46 |