Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hi,
I'm trying to create a measure that looks at columns Journey Alias and Stop Comp over 5 mins and returns either Compliant or Not Compliant for a specific Journey Alias.
Eg. 101191351 should be Not Compliant for all 3 rows, how am I able to make this?
Thanks
Solved! Go to Solution.
Hi @Anonymous ,
test =
VAR not_compliant =
CALCULATE (
COUNT ( 'Table'[Stop Comp over 5 mins] ),
FILTER (
ALL ( 'Table' ),
'Table'[Journey Alias] = MAX ( 'Table'[Journey Alias] )
&& 'Table'[Stop Comp over 5 mins] = "Not Compliant"
)
)
VAR at_all =
IF ( not_compliant >= 1, "Not Compliant", "Compliant" )
RETURN
at_all
Finally you will see:
If this is not what you want, please describe what you want, thank you!
Best Regards,
Lucien
Hi @Anonymous ,
Best Regard
Lucien Wang
Hi @Anonymous ,
test =
VAR not_compliant =
CALCULATE (
COUNT ( 'Table'[Stop Comp over 5 mins] ),
FILTER (
ALL ( 'Table' ),
'Table'[Journey Alias] = MAX ( 'Table'[Journey Alias] )
&& 'Table'[Stop Comp over 5 mins] = "Not Compliant"
)
)
VAR at_all =
IF ( not_compliant >= 1, "Not Compliant", "Compliant" )
RETURN
at_all
Finally you will see:
If this is not what you want, please describe what you want, thank you!
Best Regards,
Lucien
This doesn't work either, if you can help me share the file link then that would help as having the underlying data will help make my question easier to understand.
Hi Lucien,
How can I do that so I can share my report to you instead?
Regards,
Paolo
Hi @Anonymous ,
You can upload the .pbix file after removing sensitive data to onedrive business and share the link with me.
Hi,
I think the ALLEXCEPT() function should work. I can offer more help if you share the link from where i can download your PBI file.
Hi,
I'm not sure how to do this actually since I've never shared a powerbi file to an external user. I've published it in my workspace and clicked share there but it asks for an email address and the only link available was the report link at the bottom which I have already sent here.
If you can direct me on how to do this then I'll be able to do so since I can't find a solution for this on here.
here's the link, let me know if that works
That is not a file download link.
@Anonymous , Try this one
if(isblank(calculate(countx(filter(Table, containsstring(Table[Stop over 5 Min], "Not Complaint")),Table[Journey Alias]), filter(allselected(Table), Table[Journey Alias] =max(Table[Journey Alias])))),"Complaint","Not Complaint")
@Anonymous , Try a measure like
if(isblank(calcuate(countx(filter(Table, containsstring(Table[Stop over 5 Min], "Not Complaint")),Table[Journey Alias]), allexcept(Table, Table[Journey Alias]))),"Complaint","Not Complaint")
this measure seems to inflate the number of actual rows in the table, there's only meant to be 40 rows and this just keeps going when I scroll down and all rows turn into Not Compliant, unless I filter the Journey Aliases one by one then the measure works
@Anonymous ,
Try this one
if(isblank(calculate(countx(filter(Table, containsstring(Table[Stop over 5 Min], "Not Complaint")),Table[Journey Alias]), filter(allselected(Table), Table[Journey Alias] =max(Table[Journey Alias])))),"Complaint","Not Complaint")
User | Count |
---|---|
140 | |
113 | |
104 | |
77 | |
63 |
User | Count |
---|---|
135 | |
126 | |
110 | |
70 | |
61 |