cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
WebPortal
Post Prodigy
Post Prodigy

Filter sharepoint list column

I want to get the items in a SharePoint list, that match the following condition:

Filter a column (DateX), in date/time format, and get the records for "next week".

I should get the dates in DateX and values for other two columns (A and B).

 

So, I've created a new Flow with a daily recurrence and am now exploring the SharePoint actions, but unsure where to start. 

"Items" action?

Variables?

 

Can anyone help?

 

Thanks in advance!

1 ACCEPTED SOLUTION

Accepted Solutions

 

Hi @WebPortal ,

 

It seems that you only configure one parameter in Filter Query.

You could configure Filter Query as follows:

68.PNG

Please check this blog and see if it helps:

https://sharepains.com/2018/11/12/sharepoint-get-items-odata-filter-query/

 

Please note that we need to get the internal name of the Date column and configure it in Filter Query.

You could run Get items action without configuring Filter Query and get the internal name of the date field in the body of Get items action.

 

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

4 REPLIES 4
abm
Super User
Super User

Hi @WebPortal 

 

You need to user the Filter query against your datetime field

 

See this blog. This will give some good idea about filtering records.

 

https://baddaz.com/filtering-a-list-of-records-in-flow-based-on-todays-date-5a80292b366d

 

In your case for next week you may need to use utcNow() and Add expression to get next weeks date.

 

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

Actually, when trying to follow the instructions of the blog post, I get the error:

 

The expression "2020-18-05" is not valid. Creating query failed.
clientRequestId: 7a4

 

The formula in "get items" step is the following:

formatDateTime(body('Obter_tempo_futuro'),'yyyy-dd-MM')

 

I've tried other formats, like 'yyyy-MM-dd' and 'dd-MM-yyyy'

 

But they all return the same error.

 

 

Hi @WebPortal 

 

Thanks for your reply. Could you post a screenshot of your flow please?

 



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

 

Hi @WebPortal ,

 

It seems that you only configure one parameter in Filter Query.

You could configure Filter Query as follows:

68.PNG

Please check this blog and see if it helps:

https://sharepains.com/2018/11/12/sharepoint-get-items-odata-filter-query/

 

Please note that we need to get the internal name of the Date column and configure it in Filter Query.

You could run Get items action without configuring Filter Query and get the internal name of the date field in the body of Get items action.

 

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.

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Difinity Conference 2022

Difinity Conference 2022

Register today for two amazing days of learning, featuring intensive learning sessions across multiple tracks, led by engaging and dynamic experts.

European SharePoint Conference

European SharePoint Conference

The European SharePoint Conference returns live and in-person November 28-December 1 with 4 Microsoft Keynotes, 9 Tutorials, and 120 Sessions.

Users online (5,226)