cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
milanb
Frequent Visitor

Extracting values from an OData response and formatting my current response to be JSON Array?

Hi All,

I am trying to build a flow and copy/move a Sharepoint list item from one SharePoint list to another.

 

The issue I am having is copying/moving the data that is in choice/multi select format.

 

When I look at the output from the ‘Get Items’ action, the multi select data is brought back as “@odata.type”

milanb_0-1610987156441.png

 

Having looked at a similar issue and response provided by @DeepakS

 

Solved: Retrieve checkbox value and remove "@odata.type" - Power Platform Community (microsoft.com)

 

I have managed to retrieve the value using the following:

milanb_1-1610987156451.png

 

This has returned the output:

milanb_2-1610987156469.png

 

I now need to get this data into a multi select/choice format before I can create it in the new SharePoint list.

 

I know that I need to format my output as a JSON Array but I am unsure as to the steps.

 

I would really appreciate any assistance.

Thank you.

2 REPLIES 2
RezaDorrani
Dual Super User
Dual Super User

Hi @milanb ,

 

Not exactly your use case but updating SharePoint multiple choice column from flow - https://youtu.be/kbqXsKPTmZk?t=694

 

 --------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

Thanks,
Reza Dorrani, MVP
YouTube
Twitter

Hi @RezaDorrani

 

Thank you for the guidance.

 

I have managed to get to a point now where I can convert the output into an array, however, when I retrieved the values from "@odata.type":"#Microsoft.Azure…..”, I was unable to values together as a string

 

i.e. [“Local to your home”,”Regionally”,”Nationally”]

 

I could only get the outputs as individual strings (see below) I would get have to select ‘Next’ to select the view the next output.

 

milanb_5-1611214213886.png

 

milanb_6-1611214213897.png

 

I need to be able to create an array

[

  "Local to your home",

  "Regionally",

  "Nationally"

]

 

And then to get the following output via the Select

 

[

  {

    "Value": "Local to your home"

  },

  {

    "Value": "Regionally"

  },

  {

    "Value": "Nationally"

 

Instead of the above, I get the following from my select:

 

milanb_7-1611214213903.png

 

I have tried using the join() array function and Parse JSON without luck. Perhaps I am using it in the wrong place?

 

Below are the steps I have used

milanb_8-1611214213907.png

Thanks

Helpful resources

Announcements
 WHAT’S NEXT AT MICROSOFT IGNITE 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Register for a Free Workshop.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Users online (3,603)