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

Filter query for list records

I am having trouble building a power automate, I have added a ‘List record’ step and want to add the filter query from d365 when the statuscode = (as below) and the createdon is greater than  hours.

 

Can someone help me with the filter query as it doesn’t work.

 

 

F68CCDC1-5A6D-4EFD-8DCC-8BB023A7E97B.jpeg

 

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @AlvinH ,

 

You are using CDS connector. There is another connector : CDS(Current environment) and this connector has many actions including List records. In this List records you can specify the fetch xml as well.

 

Thanks

View solution in original post

8 REPLIES 8
Solution Sage
Solution Sage

Hi @AlvinH ,

 

Currently web api calls support only selected operators and not all. 

 

Following url will help you with that :

 

https://diyd365.com/2019/11/20/every-power-automate-ms-flow-filter-query-you-ever-wanted-to-know-as-...

 

As an alternative , please use CDS(Current) connector and use List Records there as it provides you option to add your fetchxml which you want. 

 

Thanks

 

Thanks

@ManishJain  I have tried that site before but couldn’t work out how to do it. I am already using the CDS Connector (see the image) the bit I am stuck on is getting the createdon date older than x hours.

Hi @AlvinH ,

 

You are using CDS connector. There is another connector : CDS(Current environment) and this connector has many actions including List records. In this List records you can specify the fetch xml as well.

 

Thanks

View solution in original post

Hello @AlvinH 

 

An easy route would be to use a simplified filter in your Odata filter query. Than adding a Filter array to apply advanced filtering





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

If you like my post please hit the Thumbs Up


Proud to be a Flownaut!


Check out my blog for Power Automate tips, tricks, and guides
FlowAltDelete




@Jcook  Can you share a simple example for my scenario please ?

 

statuscode = 1

createdon = older than 2 hours 

@ManishJain I used the current environment connector but now getting this error below. Any ideas

 

 

Capture.PNG

Hi @AlvinH ,

 

the error suggests you are missing record id . Can you please share screenshot . 

 

Thanks

@ManishJain this is my flow:

 
 

Capture.PNG

 

This is the error:

Capture2.PNG

Helpful resources

Announcements
PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Top Solution Authors
Users online (11,562)