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

Odata Filter documents of sharepoint library with formatDateTime doesn't work

Hi Community,

 

getting crazy with this stupid date time format expression filter.

 

In test environment we have a german sitecollection / library / date coulmn

There the filter which workfs fine with:

The coulmn show the date eg 30.6.2020
Next_x0020_Review_x0020_Due_x0020_By eq 'formatDateTime(addDays(utcnow(),-7),'yyyy-MM-dd')'

 

In Prod there is a english sitecollection and the same filter doesn't work

The coulmn show the date eg 2020/06/30

How is the correct expression for the english library / column ?

 

Best regards

1 ACCEPTED SOLUTION

Accepted Solutions
v-bacao-msft
Community Support
Community Support

 

Hi @MD2409_ ,

 

Please try to run Get items action without configuring Filter Query first and check the Body of the action.

 

Get the display name of the specified date column and check the format of the date.

 

Then you could configure Filter Query again and format the date parameter to filter items.

 

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

3 REPLIES 3
DeepakS
Super User
Super User

HI @MD2409_ 

 

Have you tried following expression in prod:

Next_x0020_Review_x0020_Due_x0020_By eq 'formatDateTime(addDays(utcnow(),-7),'yyyy/MM/dd')'

 

Regards,

ChristianAbata
Super User II
Super User II

hi @MD2409_  you can try @DeepakS  sols the format is  7/13/2017 or you can change the column format.

 

https://sharepointmaven.com/change-date-format-sharepoint/



Did I answer your question? Please consider to Mark
my post as a solution! to guide others :winking_face:

Proud to be a Flownaut!


If you want you can follow me at www.christianabata.com Quieres contenido en español? Síguenos en Power Automate LA
v-bacao-msft
Community Support
Community Support

 

Hi @MD2409_ ,

 

Please try to run Get items action without configuring Filter Query first and check the Body of the action.

 

Get the display name of the specified date column and check the format of the date.

 

Then you could configure Filter Query again and format the date parameter to filter items.

 

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

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Top Solution Authors
Users online (61,680)