Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I do not yet get set analysis that well, so this might be a dumb question.
Is it possible to make a statement that you want a field to be in something, but still selectable?
Example:
Field: EventCode
I want it to always be within specific codes. Let say 450,455 & 550. If no user selection, I want to count all of the defined codes. But if the user select one of the eventcodes, I want only that one to be counted.
What my expression looks like now:
=Count(
{
<State={1},EventCode={450,455,550},Parameter={9}>
}EventTime
)
I have tried to add the $
=Count(
{$
<State={1},EventCode={450,455,550},Parameter={9}>
}EventTime
)
=Count(
{
<State={1},EventCode={$450,455,550},Parameter={9}>
}EventTime
)
, but it did not change anything. I guess by saying "EventCode={450,455,550}", I'm actually telling it to always show the eventcodes no matter what.
So my question: Is it possible to dictate that the eventcode has to be within some values, but still make them selectable?
Yes you can; using implicit set operator '*' like:
EventCode *={450,455,550}
Hi,
try in this way:
1) add a variable
=if(GetSelectedCount(EventCode)=0,Replace(' 455 ' & ',' & ' 450 ' & ',' & ' 550 ',' ',chr(39)),chr(39) & Concat(EventCode,chr(39) & ',' & chr(39)) & chr(39))
2) then use that variable inside set analysis
EventCode={$(variable)}
Yes you can; using implicit set operator '*' like:
EventCode *={450,455,550}
@tresesco wrote:Yes you can; using implicit set operator '*' like:
EventCode *={450,455,550}
Yaaaassss. Great. Thank you 😁