Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a field named Controlxx. The value can be 'Partially Effective' , 'Ineffective', 'effective'. I am trying to count up the records for a bar chart where the value can be 'Partially Effective' , or 'Ineffective' .
My dimension is a field named 'Control'. I am unable to get this to work. Can someone shed some light for me.
What is the proper syntax?
Thanks
What this Control dimension contain?
You can take Control as Dim & Expression is:
=count({<Controlxx={'Partially Effective' , 'Ineffective', 'effective'}>} Controlxx) //you can use distinct as well
Hope this will help!!
try
count ({<Controlxx={'Partially Effective' , 'Ineffective'}>} Amount)
Hi erodman52,
Please find the attached sample file and let me know if this works for you.
Thanks,
Punit !
I wud say, in a meaningful way:
Take Controlxx as dimension and Count(Control) or count(distinct(Control)) as expression.
Hi,
What exactly are you trying to show on the Bar Chart?
Is it two bars one showing the 'Partially Effective' , 'Ineffective' and another showing 'Effective'?
If so you could use two expressions
count ({<Control={'Partially Effective' , 'Ineffective'}>} Control)
And
count ({<Control={'Effective'}>} Control)
or you could make another field in the script that groups the two for your charts
IF(Control={'Partially Effective' , 'Ineffective', 0, 1) AS Effective.
The 0 and 1 are just flag and could be anything you need.
Mark
What this Control dimension contain?
You can take Control as Dim & Expression is:
=count({<Controlxx={'Partially Effective' , 'Ineffective', 'effective'}>} Controlxx) //you can use distinct as well
Hope this will help!!
Thank you for solving my issue. I used the same construct on another bar chart, containing two dimensions.
In this case the value could be 'E', or 'M'. I get the correct values, but the first line of the chart does not contain a value, it is blank, but it contains 1175 as the count. It is skewing the other values, as I don't see the individual lines of the graph because the numbers ae small.
You can use Suppress Null Values Option in Dimension Tab