Combine two NetSuite Saved Searches output to one CSV file
Good day! I have this test flow that I'm currently working. First source tile will provide the immediate inventories and the second tile will provide the future inventories. I was hoping that when I run the flow, that it will produce only one CSV file, but it didn't.
Is there any way to combine the output of the two sources into one CSV file? Any tip or work around is much appreciated. Thanks!
-
Official comment
Hello Raul Bernales,
It is not possible to merge the data from two sources into a single CSV at this time.
For now, you can create a single saved search in NetSuite with two statuses (if the fields/columns are same) and use that in the source bubble.
-
Raul Bernales, since it may not be possible to combine the saved searches, which can often be the case for inventory searches given their complexity, you could create another flow. So flow 1 would be what you have now and there would be 2 files placed on the FTP server. You then could make a second flow that is triggered to run after the completion of flow 1. The second flow would be set to pick up the files that were placed and then will create a single file. On flow 1, I would place the files into a staging directory, then flow 2 picks from the staging directory and places in final directory.
0 -
Tyler Lamparter. That is a great tip. Let me play around with this and hope you don't mind if I get back to you if I need further assistance. Thanks!
0 -
Raul Bernales sounds good. In order to have one flow run after another, you can find the settings here on flow 1.
0 -
Tyler Lamparter I guess I will need your help as I don't know what to set to combine those two CSV files into one.
here are the parameters that I set on the FTP source tile.
and below are the parameters that I set on the Destination FTP tile.
When I ran the flow it just created the one CSV file named "file-2023-09-06T15_58_58-05_00.csv" with it's content below.
success,fileName,lastModifiedTime,fileSize,blobKey
true,,,,f184ea1297704d269964d65f8381f50b
true,,,,950c5d68fe964f2d938eec4e20b7edcbPlease let me know what I'm suppose to do. Thanks!
0 -
Raul Bernales it looks like you have parse file set to false on the source/export. Can you remake it and set to yes I want to parse the files? Your parsing strategy may be different. You even may just make the file type JSON when you temp store in staging, then convert to CSV on the FTP import step on flow 2.
0 -
Certainly. I will work on it in a few minutes and keep you posted. Many thanks.
0 -
Tyler Lamparter I followed your instructions and was successful this time. The json files were merged into one CSV file. Below is the screenshot and the numbers under the run console were the expected numbers.
Many thanks for your all your help. Wish you all the best.
1
Please sign in to leave a comment.
Comments
8 comments