Appending Plain Values Into A String Inwards Microsoft Flow

By Monday, February 5, 2018 on February 05, 2018 Tags:
Appending Plain Values Into A String Inwards Microsoft Flow.

m working on implementing a Flow which triggers on a SharePoint listing Appending plain values into a string inwards Microsoft Flowtechmikael_GenericSchema.

The approach I’ll outline does non solely apply to taxonomy fields, exactly for whatever input which has an array of objects. Below is a sample object array.

[   {     "TermGuid": "74c34307-80e8-4e21-a63b-81337e369a5c",     "WssId": 29,     "Label": "Term A",     "Path": null,     "Value": "Term A|74c34307-80e8-4e21-a63b-81337e369a5c"   },   {     "TermGuid": "db79ec09-34ad-4c60-8f4c-d41248ee09ac",     "WssId": 450,     "Label": "Term B",     "Path": null,     "Value": "Term B|db79ec09-34ad-4c60-8f4c-d41248ee09ac"   } ] 

The output should choice the Value belongings too bring together them together amongst a semicolon similar this:

Term A|74c34307-80e8-4e21-a63b-81337e369a5c;Term B|db79ec09-34ad-4c60-8f4c-d41248ee09ac

Steps

[Update – 2018-02-06]

I asked John Liu if he had some input too of course of report he did, too hither are the updated, simpler steps :)

First add together a “Data Operations – Select” step, too click the “Text mode” switch to larn i input box instead of key/value pairs.

m working on implementing a Flow which triggers on a SharePoint listing Appending plain values into a string inwards Microsoft Flow

In the map field, choice the belongings of your data.

Below the select activeness add together a “Date Operation – Join” action. In the From plain choice the output of the select, too add together choice your bring together character.

m working on implementing a Flow which triggers on a SharePoint listing Appending plain values into a string inwards Microsoft Flow

The role is that this industrial plant for empty arrays coming inwards every bit good :)

[Original]

There powerfulness live on multiple ways to accomplish this, exactly this is what I came upwards with:

First add together an “apply to each” chemical part loop which takes the array every bit input. Inside the loop add together a “Data Operations – Compose” step.

m working on implementing a Flow which triggers on a SharePoint listing Appending plain values into a string inwards Microsoft Flow

I induce got renamed my Compose pace to “ComposeSector”, too the input is the Value belongings of the object. The belongings should live on available inwards the dynamic content, or you lot tin post away add together it via an human face every bit well, referencing the advert of the loop too the object belongings itself.

@items('Concatenate_Terms_Values')?['Value']

Below the loop add together a “Data Operations – Join” action. As the input become to the human face syntax too type:

outputs('ComposeSector')  which points to the compose pace inwards the loop. You powerfulness induce got to click OK a pair of times earlier it accepts. And I’ve added a ; every bit the bring together character.

m working on implementing a Flow which triggers on a SharePoint listing Appending plain values into a string inwards Microsoft Flow

If you lot desire to handgrip empty arrays every bit well, usage the next expression:

if(empty(outputs('ComposeSector')),array(''),outputs('ComposeSector'))

When running the Flow you lot meet the values are outputted every bit expects, too are gear upwards for usage :)

m working on implementing a Flow which triggers on a SharePoint listing Appending plain values into a string inwards Microsoft Flow

Summary

Not all information operations are straight forwards inwards Microsoft Flow. Ideally I would induce got liked to the bring together operator direct instead of a loop too the bring together activeness – exactly every bit that’s non possible nosotros tin post away ever operate around the issues at hand. By grouping the steps involved inwards a range it every bit good makes the Flow easier to read.

Divide too conquer #FTW

Thanks for reading : Appending Plain Values Into A String Inwards Microsoft Flow