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

Adding days to partial date (07-Feb)

Hello PA network,

 

Seems simple and maybe I'm missing something. 

 

I am being presented with a date as text = "07-Feb" ... I just need to be able to add 6 days to it.  


I have tried a bunch of ways to make this work to no avail.

 

Any recommendations?

 

wiredup_0-1642816877423.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
ekarim2020
Super User
Super User

Try the following expression:

 

addDays(concat(outputs('Compose'),'-',concat(utcNow('yyyy'))),6,'dd-MMM')

 

This expression

  • inserts the current YEAR to the date using the concat() function: YEAR-07-FEB so we get 2022-07-FEB
  • Add 6 days
  • Format the output of the addDays() function as dd-MM to get 13-Feb

Here is the flow's runtime output:

Snag_2c07ba.png


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

View solution in original post

2 REPLIES 2
ekarim2020
Super User
Super User

Try the following expression:

 

addDays(concat(outputs('Compose'),'-',concat(utcNow('yyyy'))),6,'dd-MMM')

 

This expression

  • inserts the current YEAR to the date using the concat() function: YEAR-07-FEB so we get 2022-07-FEB
  • Add 6 days
  • Format the output of the addDays() function as dd-MM to get 13-Feb

Here is the flow's runtime output:

Snag_2c07ba.png


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

wiredup
Helper I
Helper I

Thank you! Perfect!

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.

Super User 2 - 2022 Congratulations 768x460.png

Welcome Super Users

The Super User program for 2022- Season 2 has kicked off!

Users online (3,308)