cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Super User
Super User

Using dates

I have created  aflow that gets items from a sharepoint list.  This then goes to a condition that:

 

If record is before today it creates a new item in another list.  It then deletes that item from the item list. 

 

It worked with the exception it did select the group based on date I wanted.  It selected a whole group of future dates.

 

I used utcNow() < date   where date is in the SP date column.  I hav enever worked with UTC befoe and assume I need to do someting with that to make sure.  date is a simple date, not date/time

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Advocate IV
Advocate IV

Re: Using dates

hi @leyburn19

 

You can retrieve all items by changing the limit using settings for Get Items template.

 

Thanks,

Sru

View solution in original post

3 REPLIES 3
Highlighted
Community Support
Community Support

Re: Using dates

Hi @ leyburn19,

 

Could you please share a screenshot of the configuration of your flow?

 

I have made a test on my side,I have create a sharepoint list with a "Start Date" column with "Date" type.

 

You could create the flow refer to screenshot below:

Capture.PNG

 

The expression in the condition as below:

@less(formatDateTime(items('Apply_to_each')?['Start_x0020_Date'], 'yyyy-MM-dd'), formatDateTime(utcNow(), 'yyyy-MM-dd'))

 

The flow would run successfully, and the items which's "Start Date" is less than today would be deleted,and a new item would be created in another list as below:

Capture.PNG

The items which's "Start Date" isn't less than today would do nothing as below:

Capture.PNG

 

 

Regards,
Alice Zhang

Highlighted
Super User
Super User

Re: Using dates

Thank you for teh response.  I actually found that I could filter the list at the Get Items stage with Odat filter.  Once I worked out how to look at that with utcNow() it fell into place. 

 

Another anomoly came fromn it though.  When I ran the flow I expected it do about 2500 records.  It only did 200.  Is there a flow limit in place for this type of action?  What I did was get all items before today and basically create a copy in another list

Highlighted
Advocate IV
Advocate IV

Re: Using dates

hi @leyburn19

 

You can retrieve all items by changing the limit using settings for Get Items template.

 

Thanks,

Sru

View solution in original post

Helpful resources

Announcements
FirstImage

Microsoft Ignite 2020

Check out the announcement of Power Platform content at Microsoft Ignite!

thirdImage

Experience what's new for Power Automate

Join us for an in-depth look at the new Power Automate features and capabilities at the free Microsoft Business Applications Launch Event.

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Users online (7,889)