Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I want to show a reference line and this is the expression. Somehow it's not working! It works though when I use a field name and not a variable?
Count({$<Variable1={'1'}>}distinct (field1))
Any ideas why it's not working?
Thks
In set analysis - modifiers are expected to be a field name. If your variable evaluation doesn't produce a valid field name - it wouldn't work. You can try something like:
Count(Distinct If(Variable=1, field1))
In set analysis - modifiers are expected to be a field name. If your variable evaluation doesn't produce a valid field name - it wouldn't work. You can try something like:
Count(Distinct If(Variable=1, field1))
The set analysis expects there a native field - if your variable returns one it would work. Quite probably it's not a field else an independent variable and here you need a different approach, for example like:
if($(var) = 'Condition', count(distinct field))
If the variable contains just a boolean you could also use:
count(distinct field) * $(var)
- Marcus
Thank you so much! it worked