I ran today into an scenario trying for efficiency reason to write multiple values with a single store | Value | !csvLine command into my CSV line before writing it with csvSave into my file.
This is about eliminating a Foreach / end loop that would reduce my runtime for 26 records from 10 seconds to 2.
Below is a simplified code that shows what I’m looking for (currently creating two csv columns but not 3) → “John,Doe”,hello
{
“Command”: “store”,
“Target”: “John”,
“Value”: “firstName”,
“Description”: “”
},
{
“Command”: “store”,
“Target”: “Doe”,
“Value”: “lastName”,
“Description”: “”
},
{
“Command”: “store”,
“Target”: “${firstName},${lastName}”,
“Value”: “!csvLine”,
“Description”: “”
},
{
“Command”: “store”,
“Target”: “hello”,
“Value”: “!csvLine”,
“Description”: “”
},
{
“Command”: “csvSave”,
“Target”: “names.csv”,
“Value”: “”,
“Description”: “”
}
I was thinking the best solution would be if you pass an array to store | !csvLine it would separate them automatically into the CSV line values.