Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
javvaji
Creator II
Creator II

Getting backslashes in tFileOutputJson output

Hi Team,

While i am trying to export json data to .json file using tFileOutputJson component every key and values are enclosing in backslashes. I am trying to export multiple json objects in one json file. Can any one help me on this.

Ex : {\"ID\":\"D722CAB9C24129B1\"}

 

Thanks,

Bharath.

Labels (3)
13 Replies
vboppudi
Partner - Creator III
Partner - Creator III

Please provide more details on your requirement.

 

Regards,

javvaji
Creator II
Creator II
Author

Hi @vboppudi,

 

We have to export data from table to .json file in json format. We have tried to parse and export it but while exporting data to Json file we are getting backslashes for each key and values in json.

Below is the sample record from file.

Ex : {\"ID\":\"C24129B121\",\"CUSTOMER_ID\":\"Null\"}

 

Thanks,

Bharath.

vboppudi
Partner - Creator III
Partner - Creator III

Can you please provide input data as well if possible.

Regards,

javvaji
Creator II
Creator II
Author

Hi @vboppudi,

 

Input data is as follows

 

ID,CUSTOMER_ID

C24129B121,Null

C2412AB121,AB2324

C6556JKNS,SBH6844

 

Thanks,

Bharath.

vboppudi
Partner - Creator III
Partner - Creator III

Hi,

Are you looking for the following out put?

 

0683p000009LyjG.png

 

Can you please post you job if possible?

Regards,

abo
Contributor II
Contributor II

Hello Everyone,

 

i am interested by the answer. I have same issue.

 

Here is my job and the json file in output.

 

0683p000009Lzax.png0683p000009Lzn5.png

 

My second problem is , i still have the "root" named Json in the file.

 

Or i did check "remove root node" in my tWriteJSONField

 

thank you guys.

 

 

UniperDataLake
Contributor
Contributor

Hi all,

 

Has anyone managed to resolve the issues?

 

I am using Talend Real-time Big Data Platfrom 6.4.1 (Build 20170623_1246) and 7.1.1 (20181026_1147), and experiencing exactly same issues on both versions.

 

- escape character backslash is included for every double quotation used for keys and values

- the option "Remove root node" in tWriteJSONField is not working in combination with tFileOutputJSON

 

The issue is not given when logging from tWriteJSONField into tLogRow, and writing directly from tWriteJSONField to tFileOutputDelimited.

I need to use tFileOutputJSON to put everything into a JSON array brackets.

 

 


Capture_Talend_Job.PNG
JSON_Result.PNG
MESAP_Data_Container_Dump_JSON_Test.zip
json_out.zip
UniperDataLake
Contributor
Contributor

Hi all,

 

Has anyone managed to resolve the issues?

 

I am using Talend Real-time Big Data Platfrom 6.4.1 (Build 20170623_1246) and 7.1.1 (20181026_1147), and experiencing exactly same issues on both versions.

 

- escape character backslash is included for every double quotation used for keys and values

- the option "Remove root node" in tWriteJSONField is not working in combination with tFileOutputJSON

 

The issue is not given when logging from tWriteJSONField into tLogRow, and writing directly from tWriteJSONField to tFileOutputDelimited.

I need to use tFileOutputJSON to put everything into a JSON array brackets.

 

Please let me know.

Thanks


MESAP_Data_Container_Dump_JSON_Test.zip
Capture_Talend_Job.PNG
JSON_Result.PNG
UniperDataLake
Contributor
Contributor

Hi all,

 

Has anyone managed to resolve the issues?

 

I am using Talend Real-time Big Data Platfrom 6.4.1 (Build 20170623_1246) and 7.1.1 (20181026_1147), and experiencing exactly same issues on both versions.

 

- escape character backslash is included for every double quotation used for keys and values

- the option "Remove root node" in tWriteJSONField is not working in combination with tFileOutputJSON

 

The issue is not given when logging from tWriteJSONField into tLogRow, and writing directly from tWriteJSONField to tFileOutputDelimited.

I need to use tFileOutputJSON to put everything into a JSON array brackets.

 

Please let me know.

 

Thanks