cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ElMeSaFeR
Helper IV
Helper IV

filter outputs expression

Hi, 

 

I have two SP lists ( A, B) 

list B contain a column name (Doc_ID) , It should be a reference for A list ID column 

 

A >>> ID, Title, Name, ... 

B >>> ID, Title, Doc_ID, Name, ... 

 

I have a flow with multiple steps, one them with name (Get Items for list B)

the next step is Compose with

 

outputs('Get_Items_For_list_B')

 

to give me all details, But I need to filter the outputs by a specific ID

 

I need help about the code please!

1 ACCEPTED SOLUTION

Accepted Solutions

 

Hi @ElMeSaFeR ,

 

If you want to filter items with equal values of ID and DocID, I am afraid the best option is to use Filter array. At present, we cannot directly use expression in Compose to filter an array. There is no function can achieve this.

 

I noticed that the value of DocID is a string, then you also need to use int() function to convert this value.

Image reference:

25.PNG

Hope this helps.

 

Best Regards,

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

View solution in original post

6 REPLIES 6
abm
Super User
Super User

Hi @ElMeSaFeR 

 

If you looking to filter the List B by specific ID then use the filter query to extract the values.

 

image.png

 

If your ID is numeric column then you don't need to use the single quotes around it.

 

ID eq 10

 

Thanks

 



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blog
Power Automate Video Tutorials

@abm 

Thanks a lost for your reply, but I need it in code because I'm using a "Compose" outputs already

so I need to filter this outputs 

Hi @ElMeSaFeR 

 

 Could you please explain what you meant by code and you using compose? Could you post a screenshot of your flow?

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blog
Power Automate Video Tutorials

Hello @abm 

 

this this the steps 

 

11.png

 

then this is the outputs 

 

22.png

 

I need expression like 

Outputs('GetItems') where ID = DocID 

 

to replace it in the (Compose 2) step

 

Hi @ElMeSaFeR ,

 

If you want to filter items with equal values of ID and DocID, I am afraid the best option is to use Filter array. At present, we cannot directly use expression in Compose to filter an array. There is no function can achieve this.

 

I noticed that the value of DocID is a string, then you also need to use int() function to convert this value.

Image reference:

25.PNG

Hope this helps.

 

Best Regards,

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

@v-bacao-msft 

Thanks a lot

it's working with me 

Helpful resources

Announcements
MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power automate tips 768x460 v2.png

Restore a Deleted Flow

Did you know that you could restore a deleted flow? Check out this helpful article.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Users online (3,080)