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

Held Needed with Flow

I have basic knowledge in creating flow. But some functions were unfamiliar to me.

 

I have a SharePoint list where, when an Item is created on the list. I want Flow to have a reference number which gonna use the "Created" and "ID" fields in the list. However, I only wanted to get the "year-mm" in the created field, so I try to use indexOf function. I try first indexOf(outputs('Compose'),'T') to test if I could remove the time in the field. But the result of the flow is way different from the desired output. 

 

Heres the screenshot of the Flow I created and the result of the flow:

 

Flow I createdFlow I createdResult of the flowResult of the flow

 

Hope that someone can help me with this.

 

Regards,

1 ACCEPTED SOLUTION

Accepted Solutions
Advocate I
Advocate I

Re: Held Needed with Flow

If the date field always returns in YYYY-MM-DD then you can use an expression like this:

 

int(concat(substring(outputs('Compose'),0,4),substring(outputs('Compose'),5,2)))

I tested it:

 

2019-04-17 11_26_59-Edit your flow _ Microsoft Flow.png

 

and this was the result:

 

2019-04-17 11_26_24-Run History _ Microsoft Flow.png

View solution in original post

2 REPLIES 2
Advocate I
Advocate I

Re: Held Needed with Flow

If the date field always returns in YYYY-MM-DD then you can use an expression like this:

 

int(concat(substring(outputs('Compose'),0,4),substring(outputs('Compose'),5,2)))

I tested it:

 

2019-04-17 11_26_59-Edit your flow _ Microsoft Flow.png

 

and this was the result:

 

2019-04-17 11_26_24-Run History _ Microsoft Flow.png

View solution in original post

Highlighted
Helper I
Helper I

Re: Held Needed with Flow

Thanks it works!

Helpful resources

Announcements
firstImage

Now Live: Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

Users online (9,130)