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.
Hi,
I have a fact table where each row is labeled by columns IssueType and IssueSeverity.
I need a measure that prints the most common IssueType (based on rows labeled by it) and another measure that prints row count for that issue.
Also I need similar measures for 2. common and 3. common IssueTypes and row counts.
I managed to do that for a table visual. It tells me top 3 IssueTypes and counts.
However, I want to use separate top three items on podium-like visuals or in Smart narrative visual and then using table is not an option.
I have this measure for ranking (works for table visual):
Solved! Go to Solution.
Hi, thank you for replying.
I tried your table method, but the problem was that rank values were now fixed. If I use visual slicers to filter the fact table the rank will show me always same value. It is not dynamic.
-------------------------------------------------------------------------
However. I JUST SOLVED THIS (only measures used) and here we go.
-------------------------------------------------------------------------
I needed following measures
1. Count Rows measure:
Hi, @SamiS
Glad to hear that you have solved the problem by creating the measures instead of columns yourself, would you like to mark your own reply as a solution so that others can learn from it too?
Thanks in advance!
How to Get Your Question Answered Quickly
Best Regards,
Community Support Team _Robert Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi,
According to your description, I can roughly understand your requirement, I think you can try to create a summary table to create these measures to achieve your requirement like this:
This is the test data I created based on your description:
You can first create a table like this:
Expected table =
SUMMARIZE('MyFactTable',MyFactTable[IssueType],"Count",COUNT(MyFactTable[IssueType]))
Then create two measures in the table like this:
count of 3rd common IssueType =
CALCULATE(MAX('Expected table'[Count]),FILTER(ALL('Expected table'),[Rank]=3))
what the 3rd common IssueType is =
CALCULATE(MAX('Expected table'[IssueType]),'Expected table'[Rank]=3)
And you can create a smart narrative to place the measures to get what you want like this:
You can download my test pbix file below
If this result is not what you want, you can post some sample data(without sensitive data) and your expected result.
How to Get Your Question Answered Quickly
Thank you very much!
Best Regards,
Community Support Team _Robert Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, thank you for replying.
I tried your table method, but the problem was that rank values were now fixed. If I use visual slicers to filter the fact table the rank will show me always same value. It is not dynamic.
-------------------------------------------------------------------------
However. I JUST SOLVED THIS (only measures used) and here we go.
-------------------------------------------------------------------------
I needed following measures
1. Count Rows measure:
Hello, it worked for me, now i have one more doubt
I have a another column called resolution type , i want to rank top resolution type for rank 1 issue type
for example - i want a dax measure , which basically gives me top 3 resolution type , for issue_type_rank = 1 and also give the count of resolution type.
Here in issue type , sev1 issue is ranked 1 issue type and resolution type are the top 3 resolution type of ranked 1 issue type , and also find the count of it. It should change dynamically on filters/ slicer choice applied
@SamiS ,
Change this
CountRows = CALCULATE(COUNTROWS(MyFactTable), not(isblank( (MyFactTable[IssueType] )) )
Try TOPN like
CALCULATE([CountRows], TOPN(10,ALLSELECTED(IssueTypesTable[IssueType]),[CountRows],dense), ALLSELECTED(IssueTypesTable[IssueType]))
TOPN: https://www.youtube.com/watch?v=QIVEFp-QiOk&list=PLPaNVDMhUXGaaqV92SBD5X2hk3TMNlHhb&index=42
Thank you for replying. I think I didn't get answered yet.
TOPN prints total row count of top 3 IssueTypes which is 285 in my example. That wasn't my goal.
My goal: Two measures - First shows the count of e.g. 3rd common 'IssueType' (not top 3). Second one tells me what the 3rd common 'IssueType' is.
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 |
---|---|
47 | |
24 | |
20 | |
15 | |
12 |
User | Count |
---|---|
55 | |
48 | |
43 | |
19 | |
18 |