Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am trying to have a set analysis expression that is dynamic for the country name.
Hence I want to manipulate the following expression
=num(count(distinct {<CountryName ={'United Kingdom'}>}SeriesRaceEventKey),'#,##0')
I have made a variable called vCountry but inserting this into the expression does not work.
The script editor says "Expression OK" but the result is blank.
=num(count(distinct {<CountryName =vCountry_Name_A>}SeriesRaceEventKey),'#,##0')
Am I using the wrong syntax? (If I am the script editor would indicate this as a Bad Expression ??)
Hi
Perhaps this
=count({<CountryName ={'$(vCountry_Name_A)'}>} distinct SeriesRaceEventKey)
Regards
Jonathan
Hi,
Try:
=num(count(distinct {<CountryName =$(vCountry_Name_A)>}SeriesRaceEventKey),'#,##0')
Add $ sign and the variable in brackets like below
=num(count(distinct {<CountryName =$(vCountry_Name_A)>}SeriesRaceEventKey),'#,##0')
Regards,
Sajeevan
Tired that but no luck. Perhaps it is the way I defined the variable?
I created it with:
vCountry_Name_A = 'United Kingdom'
Forgot to add the curly brackets - try this
=num(count(distinct {<CountryName ={$(vCountry_Name_A)}>}SeriesRaceEventKey),'#,##0')
I have tried that as well, still no luck.
Perhaps I should just not use a variable
Can you attach a sample QV file? There is no harm in using a variable.
Hi
Perhaps this
=count({<CountryName ={'$(vCountry_Name_A)'}>} distinct SeriesRaceEventKey)
Regards
Jonathan
Thanks Jonathan,
This works, strange solution that I would not have guessed.
I presume this is a sort of bug in QV....