Unable to get data block

Six Stars

Unable to get data block

 

Hi,

I am getting incomplete format in tfileInputDelimited as below.

 

{"name":"WDCi","locations":[{"location":"KL","staffs":[{"staff":"Lean","new_Loc":" KL"},{"staff":"Kai Herng","new_Loc":" KL KL"}]},{"location":"Sydney","staffs":[{"staff":"Walter","new_Loc":" KL KL Sydney"},{"staff":"Deborah","new_Loc":" KL KL Sydney Sydney"}]},{"location":"US","staffs":{"staff":"Terry","new_Loc":" KL KL Sydney Sydney US"}}]}

 

I need output for the same job as below.

 

{"company":

{"name":"WDCi","locations":[{"location":"KL","staffs":[{"staff":"Lean","new_Loc":" KL"},{"staff":"Kai Herng","new_Loc":" KL KL"}]},{"location":"Sydney","staffs":[{"staff":"Walter","new_Loc":" KL KL Sydney"},{"staff":"Deborah","new_Loc":" KL KL Sydney Sydney"}]},{"location":"US","staffs":{"staff":"Terry","new_Loc":" KL KL Sydney Sydney US"}}]}}

 

My job:

json.PNG

My actual data:

 

{"company":{"name":"WDCi","locations":[{"location":"KL","staffs":[{"staff":"Lean"},{"staff":"Kai Herng"}]},{"location":"Sydney","staffs":[{"staff":"Walter"},{"staff":"Deborah"}]},{"location":"US","staffs":{"staff":"Terry"}}]}}

 

Please suggest what needs to be done. Kindly reply as early as possible.

Community Manager

Re: Unable to get data block

Hi
It seems the new_Loc element is missing from the output data, you might don't configure the json tree correctly. Can you please upload some screenshots of basic settings of tWriteJsonField component?

Regards
Shong
----------------------------------------------------------
Talend | Data Agility for Modern Business

Calling Talend Open Studio Users

The first 100 community members completing the Open Studio survey win a $10 gift voucher.

Start the survey

2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog

How Media Organizations Achieved Success with Data Integration

Learn how media organizations have achieved success with Data Integration

Read

Tutorial

Introduction to Talend Open Studio for Data Integration.

Watch