cancel
Showing results for 
Search instead for 
Did you mean: 

Writing Array in CSV without formatting

aditya_gupta41
Contributor

Hello Experts,

My input contains 2 headers. In one header, the value is in JSON format.

Screenshot 2023-04-24 185212

I am trying to write it in a CSV file but as this is in array format, I am getting below error:

Screenshot 2023-04-24 185354

I tried using .toString(), but then it negates all the quotes.
I want JSON format to be intact. Below is the format in which I want CSV to be created:

Screenshot 2023-04-24 190041

Thanks in Advance

1 ACCEPTED SOLUTION

AleksandarAngel
Contributor III

Hi @aditya.gupta41,

Try with JSON.stringify() [JSON Stringify] function instead.

Let me know if this helps you.

BR,
Aleksandar.

View solution in original post

3 REPLIES 3

AleksandarAngel
Contributor III

Hi @aditya.gupta41,

Try with JSON.stringify() [JSON Stringify] function instead.

Let me know if this helps you.

BR,
Aleksandar.

Now it is coming as :
Screenshot 2023-04-24 192835

Require it as no \ and in single column. I think i might need to change something in CSV formatter snap.

aditya_gupta41
Contributor

Its done. Escape character in CSV formatter is suppose to be blank.

Thanks Aleksandar for your quick help.