Parse csv file that have a json column

Hello, everyone,

Infrastructure_monitor.zip (386 Bytes)

I have a csv file and some columns in the attached file that have a json notation.

I need to read this CSV file with a CSV Reader node, and use the node String to Json to get the JSON column. But I always get the following error:

ERROR String to JSON 0:384 Execute failed: Unexpected character (‘a’ (code 97)): was expecting double-quote to start field name at [Source: java.io.StringReader@412ba3; line: 1, column: 3] (edited)

Anyone can help please?

Hi there @Peter29 ,

replace ' with " in String Manipulation node prior too String to JSON node.

replace($metadata$,"'" ,"\"" )

Br,
Ivan

Many thanks for your help ipazin. Worked :slight_smile:

1 Like

Hi there @Peter29,

glad it helped :wink:

Br,
Ivan

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.