cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Store Value into Middle of Array

Hello,

 

I need some assistance with arrays in Microsoft Flow. I need to be able to store a value into the middle of an array that has already been initialized (cannot use append to array). I understand how to access an element of an array, so this is not my question. I instead do not know how to store a new value into an element without adding the new element to the end!

 

This is quite simple in normal programming, but I have no idea how I would do this in Flow. Any help would be greatly appreciated.

1 ACCEPTED SOLUTION

Accepted Solutions
v-yamao-msft
Community Support
Community Support

Hi @Anonymous ,

 

Do you want to add other elements in the middle of an array?

 

I am afraid that we are not able to store a new value into an array without adding the new element to the end.

 

I have made the following test using function union, please check it for a reference.

 

Function in Compose:

createArray('test1','test2','test3')

 

Function in Compose2:

union(outputs('Compose'),createArray('test4'))

1.PNG2.PNG

 

 

Best regards,

Mabel          

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-yamao-msft
Community Support
Community Support

Hi @Anonymous ,

 

Do you want to add other elements in the middle of an array?

 

I am afraid that we are not able to store a new value into an array without adding the new element to the end.

 

I have made the following test using function union, please check it for a reference.

 

Function in Compose:

createArray('test1','test2','test3')

 

Function in Compose2:

union(outputs('Compose'),createArray('test4'))

1.PNG2.PNG

 

 

Best regards,

Mabel          

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (1,381)