I have a get variable module that grabs data from text aggregators:
I want to then merge them all into one using a text aggregator:
It doesn’t quite work, it doesn’t put a comma separator in:
Am I doing this right or is there a better way?
I have a get variable module that grabs data from text aggregators:
I want to then merge them all into one using a text aggregator:
It doesn’t quite work, it doesn’t put a comma separator in:
Am I doing this right or is there a better way?
Hi @MaxW
For your information The Text Aggregator is meant to combine text values from multiple bundles into one string. It’s not intended to insert separators manually within each variable.
Let us know if you’d like an example!
If you need to have “,” between the following variables, you can simply add the comma directly when mapping the variables into the module—there’s no need to use a Text Aggregator in this case.
Best regards,
Msquare Automation
Platinum Partner of Make
@Msquare_Automation
Slightly confused, in my example data_FA and data_FS both output 2 json objects each. The data that is passed into each of those variables is setup like so in a text aggregator:
I both cases 2 products were passed through resulting in 2 comma separated json objects.
I then store that result as a variable e.g data_FA and data_FS.
I’m trying to then do the same thing with a text aggregator as I need the structure to combine all into one e.g:
data_FA,
data_FS
And don’t add a comma to the last item. So far there are up to 4 variables of stored data I could get, and in any combination e.g
data_FA,
data_FD,
data_FS
or
data_FA,
data_FD,
data_FS,
data_EL
or
data_FA
data_EL
or
data_FA
The goal is to then put it into this final structure:
{
"data": [
{
"Quoted_Items": [
{{137.text}} <--- placed here
],
"Subject": "Make Proposal",
"Proposal_Owner": {
"id": "6685677000000502001"
},
"Contact_Name": {
"id": "6685677000001013001"
},
"Company_Name": {
"id": "6685677000001374001"
}
}
]
}
So I’m trying to figure how to get that type of structured output. Please let me know what I could do here as its been something I’ve struggled with figuring out.
Hey Max,
text aggregator is meant to be put after an iterator module or any module that returns multiple bundles (like search or list modules). The goal is to combine the multiple bundles back in to one bundle. The Get Variables module is not such a module so it wont work as you expect it.
If you want to combine all the variables in a new comma separated string, then just do it in a set variables module.
That sounds like what I need to change, but how would I do this?
As it will always vary in the data, ideally I want to get the data from data_FA data_FD data_FS data_EL and place a comma between each, and if there’s only one dont add a comma
Heres a form example submission that data is coming from one flow:
But if there were 2 flow outputs e.g 1st and 2nd route, with 2 results in each, I need a comma inbetween both routes. So data_FA, data_FS
You mentioned using a set variable, how would that work in this use case? as I store the result from each product category in different routes, I need to get their results and merge them back together as one.
Would love to see an example!
This is the current state:
Create required structure and map data points:
Example of the output, here the form submitted 2 products in this product category (note I place a comma between objects):
I then store the output after the module:
I then want to merge all the data into one, and separate with a comma, except the last item. If only one, then no comma required. Here I used the get variables since they are store within another route.