Compare Parameter with string in title/subtitle

I am trying to create a dynamic subtitle with ifelse logic inside of a subtitle

ifelse( ${Metric} = 'Metric 1', "Description 1", "Description 2") is always giving Description 2 even if the Metric Parameter is selected as Metric 1

I tested ${Metric} = 'Metric 1' block separately, and it is always giving false as well.

I wonder what’s the cause and how to resolve the issue.

I tested the method in text visual, it works fine. I can get dynamic description.

Is this a bug? Why the same method works in text visual, but not in title/subtitle?

Hi @wp_quicksight_user, what type of visual are you trying to create the subtitle for?

Hi @Steph

The one with the issue is pivot table subtitle.
The one without the issue is text box.

Can you share a screenshot please? I’m not able to see where you’re creating a function in a subtitle

@Steph Here is the screenshot.

Screen Shot 2023-03-22 at 10.49.12 AM

Can you paste the ${Metric} value that comes back?

Just add a value that is ${Metric}

@Max
${Metric} can be returned correctly, however the entire block ifelse( ${Metric} = 'Metric 1', "Description 1", "Description 2") is returning Description 2 all the time.

And ${Metric} says ‘Metric 1’?

yes. ${Metric} says ‘Metric 1’ in both text visual and title and subtitle in other visuals.

ifelse( ${Metric} = 'Metric 1', "Description 1", "Description 2")this method works in text visual. And that satisfied my needs.

I just don’t know why it doesn’t work on title or subtitle in other visual.

Hmm this is weird.

I would suggest opening up a support case.

Here are the steps to open a support case. If your company has someone who manages your AWS account, you might not have direct access to AWS Support and will need to raise an internal ticket to your IT team or whomever manages your AWS account. They should be able to open an AWS Support case on your behalf. Hope this helps!