cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Equal condition case sensitive

How to make a condition case insensitive?

For example [Task] equal Salary then ...

 

I want make a condition like [Task] equal Salary or salary then ...

How do i make a condition like this in Flow?

3 REPLIES 3
Community Support Team
Community Support Team

Re: Equal condition case sensitive

Hi @Anonymous,

 

We could modify the condition formula directly through Advanced options, assuming the parameter for the [Task ] is the following:

Item()?['Task']

(You shuold be able to find the proper code for Task when click Advanced option of the condition with the Task Dynamic Content inputted)

Then the formula should be:

@or(
    equals(item()?['Task'], 'Salary'),
    equals(item()?['Task'], 'salary')
    )

Regards,

Michael

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Re: Equal condition case sensitive

Hi Micheal,

 

Thank you for your response. I wasn't clear, sorry! I am talking about an Case condition without Advanced options.

 

The situation is: first I have a condition and the I am using a switch and in the Case there is a condition "Equal to Salary". My question is, is it possible to make one Case condition "Equal to Salary or salary" or must i use two cases 1) "Equal to Salary" 2) "Equal to salary"? 

 

Best regards, Jeroen

BenBarreth
Level: Power Up

Re: Equal condition case sensitive

Edit the condition in advanced mode, then wrap it in the toLower() method: 

 

https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-workflow-definition-language

(method is 1/3rd of the way down, under string functions).

 

For example, if you want to detect the word "Salary" in either the body or subject line, try the following: 

@or(contains(toLower(triggerBody()?['Body']), 'salary')), contains(toLower(triggerBody()?['Subject']), 'salary'))

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors (Last 30 Days)
Users online (4,936)