Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Answered

Get Items filter query is getting failed when filter value contains single code value

(1) ShareShare
ReportReport
Posted on by 102

1. I am using getitems to retrive the value from a Sharepoint List with a column 1 with Single code value.

2. When i am using column 1 in the filter query , flow is getting failed where ever column values are having data with single code.

    Example : Column name is Company. Values are follows

    1. Company Test 1

    2. Company 'Test 2'

    3. Company Test 3

 

Flow is getting failed while retriving value for Company 'Test 2'.

 

Kindly help here,

  • RamKan2021 Profile Picture
    102 on at
    Re: Get Items filter query is getting failed when filter value contains single code value

    Thanks Sanmesh for the quick reply and solution , it is working fine.

  • Verified answer
    SanmeshG Profile Picture
    1,947 Super User 2025 Season 1 on at
    Re: Get Items filter query is getting failed when filter value contains single code value

    Hi @RamKan2021  ,

     

    If you are trying to create an OData filter query with single quotes in your dynamic content , then try replacing the single quotes in the expression with another single quotes which will eventually create an escape sequence for the content in single quotes.

     

    Adding the screenshot and the expression for your reference , 

    Title eq '@{replace(triggerOutputs()?['body/Title'], '''', '''''')}'

     

    SanmeshG_1-1721039260649.png

    SanmeshG_2-1721039339753.png

     

    Hope this helps , do give this a thumbs up and mark this response as a solution if this answers your question.

     

    Thanks,

    Sanmesh

     

     

     

  • creativeopinion Profile Picture
    10,439 Super User 2025 Season 1 on at
    Re: Get Items filter query is getting failed when filter value contains single code value

    @RamKan2021 Can you share a screenshot of your flow? It's hard to offer any recommendations without seeing the error. If you are using the new designer, toggle it off and click each action to expand it. Upload a screenshot of your flow in edit mode and the error you are receiving, it would help to provide more insight.

     

    Also, is your flow actually failing? If so, what is the error. Or is the Get Items action just not returning any results.

     

    You will need to use the internal column name of the column you are using in your filter query field. Keep in mind that the internal column name may not always match the name displayed in your Sharepoint list. If you aren't sure how to get the Internal Column name, you can refer to this section of one of my YT Tutorials.

     

    Not sure how to write a filter query? Check out this YT short.

     

    In the meantime, you may be interested in this YT Tutorial: 5 Power Automate Troubleshooting FAQs and Helpful Tips for Creating Better Flows

     

    In this Power Automate tutorial, I explore 5 frequently asked questions that pop up when troubleshooting a flow. If you’d like to to level up your Power Automate flow skills and learn how to troubleshoot your Power Automate flow—this tutorial is for you!

     

    IN THIS VIDEO:

    ✅ How to troubleshoot a false Condition action result

    ✅ How to get dynamic content when it isn’t selectable from the list of dynamic content

    ✅ How to troubleshoot an Apply to Each action that isn’t looping through

    ✅ How to troubleshoot a skipped Apply to Each action

    ✅ How to troubleshoot a Filter Query

    ✅ How to use a SharePoint yes/no column in a Filter Query

    ✅ How to use Compose actions to troubleshoot a Power Automate flow

    ✅ How to troubleshoot multiple emails being sent

    ✅ How to troubleshoot multiple Teams messages being sent

     

    Hope this helps!

    If I helped you solve your problem—please mark my post as a solution ✅.
    Consider giving me a 👍 if you liked my response!

    👉 Level up your Power Automate skills by checking out my tutorials on YouTube
    👉 Tips and Tricks on TikTok and Instagram

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 566 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 516 Super User 2025 Season 1

#3
stampcoin Profile Picture

stampcoin 492