cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
JWylie
Regular Visitor

Get Items filter query

Currently working on a flow to pull events from my SharePoint Calendar. As of now without using a Filter Query I am able to receive a email pulling all results past and present date. I am looking to receive the email at the first of the month that will collect all events for that up coming month. 

 

I thought this would solve it but I am getting a failure. "The expression "Calibration_x0020_Due_x0020_Date gt 2021-09-10T20:20:17.7473837Z and Calibration_x0020_Due_x0020_Date lt 2021-11-09T20:20:17.7473837Z" is not valid. Creating query failed."

JWylie_0-1631308268458.png

Hoping the community could provide me some feedback on what I am doing wrong.

 

Thanks in advance!

2 ACCEPTED SOLUTIONS

Accepted Solutions
ekarim2020
Community Champion
Community Champion

This could be due to a typing error for the field name.

Go to the  List (or Library) Settings page agaon, then select (click)  your column Calibration Due Date.

This should open the Edit Column screen.  Example:

ekarim2020_2-1631317271172.png

Now look at the address bar of the browser window. Go to the end of the URL and look for the Field=

ekarim2020_0-1631317233468.png

ekarim2020_1-1631317246730.png

This will give you the field name that you should be using in the query.

Ellis

View solution in original post

Hi @JWylie 

 

Please have a look at the below video

 

https://www.youtube.com/watch?v=L4vpYLfwTRk&t=10s

 

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

View solution in original post

5 REPLIES 5
abm
Super User
Super User

Hi @JWylie 

 

Couple of things

1. After you conditional operator gt or lt you need a single quotes then set your expression and finally again add another single quotes.

2. For date query you need to use the formatDateTime() expression using format 'yyyy-MM-dd'

 

eg: formatDateTime(utcNow(), 'yyyy-MM-dd')

 

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
JWylie
Regular Visitor

Hi @abm 

 

Thank you for replying - Currently still getting a error but it is different this time. 

 

I have changed the filter query to your suggestion and posted it below: 

JWylie_0-1631313690870.png

How will it know to pull 30days from the start of the scheduled run? Also the error I am receiving is this 

Column 'Calibration_x0020_Due_x0020_Date' does not exist. It may have been deleted by another user.

 

Here is a screen shot from the settings that shows it does exist. 

JWylie_3-1631314407875.png

 

 

 

ekarim2020
Community Champion
Community Champion

This could be due to a typing error for the field name.

Go to the  List (or Library) Settings page agaon, then select (click)  your column Calibration Due Date.

This should open the Edit Column screen.  Example:

ekarim2020_2-1631317271172.png

Now look at the address bar of the browser window. Go to the end of the URL and look for the Field=

ekarim2020_0-1631317233468.png

ekarim2020_1-1631317246730.png

This will give you the field name that you should be using in the query.

Ellis

View solution in original post

Hi @JWylie 

 

Please have a look at the below video

 

https://www.youtube.com/watch?v=L4vpYLfwTRk&t=10s

 

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

View solution in original post

JWylie
Regular Visitor

Thank you @abm@ekarim2020 

 

My issue was I was not adding the correct field name. Thanks again!

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Solution Authors
Top Kudoed Authors
Users online (1,670)