cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
thamilton
New Member

Create a Flow to run from a SharePoint doc library review date

I have a SharePoint document library with Review Date and Document Owner columns . I want to create a Flow that sends an email to the Document Owner when the Review Date is reached. Any flow I've tried works but I cannot get a condition of 'review date = today' to work. Any ideas?

2 ACCEPTED SOLUTIONS

Accepted Solutions
ScottShearer
Super User
Super User

@thamilton:

 

Below is an example of a Flow that runs successfully and should meet your needs.

In my Flow, I am using an OData filter so that only documents that have a due date of today are returned - this is a better way than retrieving all documents and using a condition/if statement.

 

When using an OData filter to filter SharePoint data, you need to use the internal column name rather than the display name (the name you see).  The two are not always the same.  To get the internal column name, go to library settings and click on the column.  The column name will be at the end of the URL.

 

I am formatting the date to match the SharePoint format.  Please note the single quotes around the expression.

 

Let me know if you need additional help.

 

DocLibFilter1.jpgDocLibFilter2.jpg

 

If this meets your needs, please mark your post as Solved.

 

Scott

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott

View solution in original post

Hi @ScottShearer,

 

Have you take a try with @ScottShearer's solution.

 

iI agree with @ScottShearer's solution, please take a try with his solution and let me know if your problem could be solved.

 

Best regards,

Alice

View solution in original post

6 REPLIES 6
RobElliott
Super User
Super User

In your condtition control it should be Review Date is equal to utc(Now()).

 

Rob

ScottShearer
Super User
Super User

@thamilton:

 

Below is an example of a Flow that runs successfully and should meet your needs.

In my Flow, I am using an OData filter so that only documents that have a due date of today are returned - this is a better way than retrieving all documents and using a condition/if statement.

 

When using an OData filter to filter SharePoint data, you need to use the internal column name rather than the display name (the name you see).  The two are not always the same.  To get the internal column name, go to library settings and click on the column.  The column name will be at the end of the URL.

 

I am formatting the date to match the SharePoint format.  Please note the single quotes around the expression.

 

Let me know if you need additional help.

 

DocLibFilter1.jpgDocLibFilter2.jpg

 

If this meets your needs, please mark your post as Solved.

 

Scott

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott

Hi @ScottShearer,

 

Have you take a try with @ScottShearer's solution.

 

iI agree with @ScottShearer's solution, please take a try with his solution and let me know if your problem could be solved.

 

Best regards,

Alice

Hi Scott,

 

Sorry, i've only now got round to trying out your solution but the flow is failing and stating the expression is not valid. I'm getting the column name from the address bar in the Edit Column page and my filter query is

 

Review%5Fx0020%5FDate eq formatDateTime(utcNow(),'yyyy-MM-dd')

 

Any ideas?

Make sure the expression part of the filter has ' before and after it. You can see this in the images earlier in the thread.

 

Rob
Los Gallardos

I do have ' around the expression, my query matches the example above exactly bar the date field name

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

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.

MPA Licensing.jpg

Ask your licensing questions at the Power Automate AMA!

Join Priya Kodukula and the licensing team, super users and MVPs to find answers to your questions on Power Automate licensing.

Users online (3,243)