cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper I
Helper I

Flow Just Stopped Working (due to dates)

Hi,

 

I have a flow that has been working without problem for 2 weeks and today it failed and I cannot workout why.

 

Fails at Filter Array

 

@equals(addDays('1899-12-30', int(item()['ADDENDUMDATE']), 'dd-MM-yyyy'), utcNow('dd-MM-yyyy'))

 

This is the error details

 

The execution of template action 'Filter_array' failed: The evaluation of 'query' action 'where' expression '@equals(addDays('1899-12-30', int(item()['ADDENDUMDATE']), 'dd-MM-yyyy'), utcNow('dd-MM-yyyy'))' failed: 'The template language function 'int' was invoked with a parameter that is not valid. The value cannot be converted to the target type.'.

 

Hopefully this is just a temporary issue with Power Automate however if someone know a better way it would be great to know.

 

Screenshot 2021-01-20 173347.jpgScreenshot 2021-01-20 173557.jpg

 

Thank you

 

Clint

1 ACCEPTED SOLUTION

Accepted Solutions

@CFernandes I found the solution.

 

formatDateTime(item()?['DUE DATE'],'dd-MM-yyyy')
 
Thanks for replying to my question.

View solution in original post

5 REPLIES 5
Super User III
Super User III

@ClintRB 

 

Hey Mate,

 

Microsoft has recently changed how Date and time are managed. It does not return a serial value.

 

See the twitter status-  https://twitter.com/mofumofu_dance/status/1349947965981356032 

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

@CFernandes  thankyou for the quick reply.  Do you know of or can you suggest a solution? 

 

Thanks

Clint

Hey @ClintRB ,

 

I think direct comparison should work now.

 

formatDateTime(<your row value,'yyyy-MM-dd')

 

is equal to 

 

formatDateTime(utcNow(),'yyyy-MM-dd')
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Hi @CFernandes thanks again but still no joy.  If hjave tried all of the recommended formats but keep getting

 

"DUE DATE": "@formatDateTime('DUE DATE','yyyy-MM-dd')"
}' failed: 'In function 'formatDateTime', the value provided for date time string 'DUE DATE' was not valid. The datetime string must match ISO 8601 format.'.

 

If I dont use an expression then this is the result I keep getting.

Screenshot 2021-01-21 141306.jpg

Cheer

Clint

@CFernandes I found the solution.

 

formatDateTime(item()?['DUE DATE'],'dd-MM-yyyy')
 
Thanks for replying to my question.

View solution in original post

Helpful resources

Announcements
Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

New Super Users

Meet the Power Automate Super Users!

Many congratulations to the Season 1 2021 Flownaut Crew!

Microsoft Ignite

Microsoft Power Platform: 2021 Release Wave 1 Plan

Power Platform release plan for the 2021 release wave 1 describes all new features releasing from April through September 2021.

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Users online (31,557)