Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Write Table now available in Qlik Cloud Analytics: Read Blog
cancel
Showing results for 
Search instead for 
Did you mean: 
rajupillai
Contributor
Contributor

Creating a JSON file from a CSV file

I have a csv file with data :

 

ID, Name,Age,Gender,City

10,John Doe,52,M,Austin

20,Mary Jane,42,F,New York

30,JackThomas,20,Atlanta

 

I like to create a JSON file that looks like 

{
"DocumentStream": [

{ "_id": "10"

   "NAME": "John Doe"

   "Age": "53"

   "Gender": M"

   "City": "Austin"

  },

{ "_id": "20"

   "NAME": "Mary Jane"

   "Age": "42"

   "Gender": "F"

   "City": "New York"

  },

{ "_id": "30"

   "NAME": "Jack Thomas"

   "Age": "20"

   "Gender": "M"

   "City": "Atlanta"

  }

 ]

}

 

I am pretty new Talend and been struggling with this

Labels (4)
1 Solution

Accepted Solutions
DataTeam1
Creator
Creator

Here is the solution:

 

0683p000009M3O0.jpg0683p000009M3OJ.jpg

 

JSON FILE:

 

0683p000009M3Lq.jpg

View solution in original post

3 Replies
DataTeam1
Creator
Creator

Here is the solution:

 

0683p000009M3O0.jpg0683p000009M3OJ.jpg

 

JSON FILE:

 

0683p000009M3Lq.jpg

rajupillai
Contributor
Contributor
Author

Awesome DataTeam !  Can I use this to insert into my MapRDB - JSON using the tMapROJAIOutput component ?  

 

DataTeam1
Creator
Creator

I don't know @rajupillai I have never used MapRDB