web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id : yeAysc5SiXXb9l7TsVuiF/
Power Automate - Building Flows
Unanswered

Filter SQL table with odata by a list of comma-seperated unique ids inside an SQL Get Rows Action Filter Query

Like (0) ShareShare
ReportReport
Posted on 31 Aug 2023 08:25:48 by

Hi,

I am trying to build a flow where I am passing list of unique ids in comma separated string.
I want to use this list to read the user's information from SQL, but I am not good with odata query filters, I am getting an error when I test the flow.

Can anyone suggest a solution?  - how to filter with list of ID's and get information of those ID's

 

Example :

Filter Query : ColumnName in ( 67, 68, 72)

 

Thanks!!

I have the same question (0)
  • 55552 Profile Picture
    669 on 16 Apr 2024 at 15:35:31
    Re: Filter SQL table with odata by a list of comma-seperated unique ids inside an SQL Get Rows Action Filter Query

    what if your list of items to filter by was variable each time the flow ran? Any way to handle that? I may have a list like "A", "B", "D", "F". Can I use some sort of concatenate function with a compose statement prior to the Get Rows action to convert that to MyColumnName eq 'A' or MyColumnName eq "B", etc.?

  • hemajm Profile Picture
    on 04 Sep 2023 at 07:57:17
    Re: Filter SQL table with odata by a list of comma-seperated unique ids inside an SQL Get Rows Action Filter Query

    Thank You !! @lbendlin 

     

  • lbendlin Profile Picture
    8,166 Super User 2025 Season 2 on 01 Sep 2023 at 14:48:41
    Re: Filter SQL table with odata by a list of comma-seperated unique ids inside an SQL Get Rows Action Filter Query

    I did some tests, and guess what - the IN operator is not supported in that filter query. HOWEVER (!!!) the OR operator is supported (even though it should not be!)

    Try this one 

     

    CTR_ID eq '000001994' or CTR_ID eq '000000932'

  • hemajm Profile Picture
    on 01 Sep 2023 at 14:06:25
    Re: Filter SQL table with odata by a list of comma-seperated unique ids inside an SQL Get Rows Action Filter Query

    Thanks for the response!!😊

     

    Here my column name is CTR_ID and I am passing list of unique ids in comma separated string to SQL to get the rows of those ID's

     

    The Query I am passing is CTR_ID in ('000001994','000000932')

     

    hemajm_0-1693576929850.png

    can you suggest me with right query.

  • lbendlin Profile Picture
    8,166 Super User 2025 Season 2 on 01 Sep 2023 at 11:18:27
    Re: Filter SQL table with odata by a list of comma-seperated unique ids inside an SQL Get Rows Action Filter Query

    It is not clear what position 9 is - can you please clarify?

     

    May need extra escaping of the single quotes.

  • hemajm Profile Picture
    on 01 Sep 2023 at 05:53:10
    Re: Filter SQL table with odata by a list of comma-seperated unique ids inside an SQL Get Rows Action Filter Query

    I am facing this issue with the filter query can you help me with right one.

    hemajm_1-1693547443200.png

     

    hemajm_0-1693547410518.png

     

    Thanks!!

  • lbendlin Profile Picture
    8,166 Super User 2025 Season 2 on 01 Sep 2023 at 00:07:11
    Re: Filter SQL table with odata by a list of comma-seperated unique ids inside an SQL Get Rows Action Filter Query

    That should work. Please show what you have done so far.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Tomac Profile Picture

Tomac 986 Moderator

#2
stampcoin Profile Picture

stampcoin 699 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 577 Super User 2025 Season 2

Loading complete