How to set the default value of a parameter of an analysis with a value type of MULTI_VALUED to blank

I want the default value of the parameter for the analysis whose value type is MULTI_VALUED to be blank.
This can be done by activating the following checkbox In the analysis edit.

If the following checkboxes are enabled in the analysis edit and the analysis definition is retrieved via the AWS CLI, the parameters are as follows.

<snip>
ParameterDeclarations:
  - StringParameterDeclaration:
      ParameterValueType: MULTI_VALUED
      Name: list
      DefaultValues:
        StaticValues: []
      ValueWhenUnset:
        ValueWhenUnsetOption: "NULL"
<snip>

However, this is not possible in CloudFormation.
When I deploy CloudFormation with [] in StaticValues and retrieving the analysis definition via AWS CLI, the parameters are as follows.
Furthermore, check boxes are disabled.

<snip>
    - StringParameterDeclaration:
        ParameterValueType: MULTI_VALUED
        Name: list
        DefaultValues: {}
        ValueWhenUnset:
          ValueWhenUnsetOption: "NULL"
<snip>

Hello @shinya.sakae, is there a reason you want to force a blank default? Are you filtering based on this parameter and trying to hide the related data on load or are you wanting it to default to all options?

Hi @DylanM .
Thanks to reply!

I would like to default to having no items selected in the dropdown.

If all are selected by default, an operation to exclude multiple items in order to select one item is required.

If the default is empty, the operation of selecting one item is very simple.

Hello @shinya.sakae, this is a cool idea so I want to try to sort out a solution. If it was a list of strings I would say to try adding empty quotation marks (" ") into the static array. This is a shot in the dark, but maybe you can try entering NULL as a default?

1 Like

Hello @shinya.sakae, did the solution I suggested above function the way you were expecting? I am curious what the end result was. Let me know and we can try to figure out an alternate solution if it didn’t work.