Forum Discussion
Field Parameter Contains Field Also Used in Measure
- 1 year ago
Thank you for response Anonymous .
I logged on this morning to post that I have solved part of the problem, but now have encountered a new problem.
This how I solved the bar chart issue:
1. I created this measure:
LOF_Backlog Insight = VAR SelectedParameter = SELECTEDVALUE(_LTCR_Dimension_par[Reg-Prog-Priority_par Order]) Var SelectedInsight = SELECTEDVALUE(_LTCR_Insights_par[_LTCR_Insights_par Order]) //Determine the parameter values selected. If LOF Insight and Program dimension RETURN SWITCH( TRUE(), SelectedParameter = 1 && SelectedInsight = 2,[LOF Backlog by Program], [LOF Backlog] )I put the measure above into the insights parameter and the bar chart works perfectly now.
However, now the card visual returns a 0 when selecting both the LOF Backlog and Program parameter values.
This a screen shot of the bar chart & card visual (upper left corner). The card visual should not display 0.
I would willingly share data, but I don't know what data to share that could help solve this issue.
In the meantime, I will mark this problem as solved as I did solve the original problem.
Thank you again to Shahid12523 & FarhanJeelani for their response.
Your measure returns the same total for each program because it's not context-aware. To fix it, rewrite the measure like this:
LOF Backlog by Program =
VAR SelectedProgram = SELECTEDVALUE('RS Cases'[Program])
RETURN
IF(
SelectedProgram IN {"Assisted Living", "DAHS", "DAHS-ISS", "DAHS-ISSONLY"},
CALCULATE([Backlog], 'RS Cases'[Program] = SelectedProgram),
0
)
This gives individual counts for each LOF program, zero for others, and removes the blank bar. Clean and accurate.
Thank you so much for your response. Your solution works but only if I select the Program field parameter. If I select another parameter, it returns nothing.
What do I need to add to the measure for it to work with the other field parameters?
- Anonymous1 year agoNot applicable
Hi Txtcher,
Thank you for reaching out to the Microsoft fabric community forum.
I would also take a moment to thank Shahid12523, FarhanJeelani for actively participating in the community forum and for the solutions you’ve been sharing in the community forum. Your contributions make a real difference.
Also, can you share a sample pbix file so that we can try to reproduce the issue from our side.
Regards,
Harshitha.