Can I use a multi-value parameter to display all or some of the parameter values

I want to use a multi-value parameter to control which columns display. This question is similar to this solution, but is for multiple values (programs).

sample dashboard:

The AI agent suggested the following steps:

  1. Create multi-value parameter
  2. Create control for multi-value parameter, using dynamic column.
  3. Create calculated field for a dynamic measure.

I am getting stuck on the calculated field.

AI recommended calculated field. But the QS editor returns a syntax error

// column 1

switch(
  ${EuATSmultifilter},
  'eu only - sc gen 1.0', {eu only - sc gen 1.0},
  'eu only - sc gen 2.6', {eu only - sc gen 2.6},
  'eu only - sc gen 4.0', {eu only - sc gen 4.0},
  'Not Selected'
)

I also tried using ifelse too:

// column 1

ifelse(
'eu only - sc gen 1.0)', in [${EuATSmultifilter}], {eu only - sc gen 1.0},
'eu only - sc gen 2.6)', in [${EuATSmultifilter}], {eu only - sc gen 2.6},
'eu only - sc gen 4.0)', in [${EuATSmultifilter}], {eu only - sc gen 4.0},
 'Not Selected'
) 

Hi @markusen,
I was holding off on replying in case someone else may have been able to formulate a work around in this scenario but from my further testing; I believe this is a current limitation with multi-value parameters.
Each column that populates in a table needs to have it’s own field that’s included in the field well. So while you could essentially change what field is being used in a column through an ifelse; it can’t create new columns based on more than one value being selected.

I can mark this as a feature request to promote visibility to the AWS support team.

1 Like

ProgramSelectorParam

Hi @markusen,
I’m not sure if there was supposed to be sound with that video but if so, I was unable to hear any explanation. Could you let me know what you’re showcasing in that example?

The animated GIF is to demonstrate how the template control changes the table and KPIs.