Create JSON structure with multiple values

Two Stars

Create JSON structure with multiple values

Hi, I need help with creating JSON structure. I need to get it look like this:

"dps":[ { "x":1485801000000, "y":[ 37.22, 37.37, 36.64, 36.82 ] }, { "x":1485714600000, "y":[ 37.74, 37.84, 37.33, 37.42 ] }, { "x":1485455400000, "y":[ 38.0, 38.45, 37.81, 37.98 ] }

 It means that there is one loop called "dps" containing array of data. Each part of this loop cantains two elements x and y. X has single value, but Y has multiple values (array).


This is how my input data looks like:




My x value is in the first column of each row. Y values are stored in other four columns. I tried almost everything with tWriteJsonField but no success came out.


Does anyone have an idea how to deal with it?

Tags (2)

Re: Create JSON structure with multiple values


Could you please take a look at this webpage:

Here is a related topic:

Best regards



Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.


Introduction to Talend Open Studio for Data Integration.

Definitive Guide to Data Integration

Practical steps to developing your data integration strategy.

Definitive Guide to Data Quality

Create systems and workflow to manage clean data ingestion and data transformation.