🎉Community Raffle - Win $25

An exclusive raffle opportunity for active members like you! Complete your profile, answer questions and get your first accepted badge to enter the raffle.
Join and Win

Combining JSON output into a single field

User: "Shawn_21372"
Altair Community Member
Updated by Shawn_21372
Hi,
 
I have a file with data in JSON format that is an output from a Dataprep Studio workspace.  I would like to combine this output into a single field which would eventually be appended with another file that is being ingested into a database table.  Here is an example of the JSON file:
 
[ 	{ 		"Field1": "1", 		"Field2": "2", 	}, 	{ 		"Field1": "1", 		"Field2": "2", 	} ]
 
Here is an example of the final format that would be loaded to a database table:
 
Field1 Field2 JsonOutput Field4
Some value 2 [
    {
        "Field1": "1",
        "Field2": "2",
    },
    {
        "Field1": "1",
        "Field2": "2",
    }
]
Some Value
 
Is there any way out of the box I can combine the JSON file into a essentially a single field?
 
Thanks!

Find more posts tagged with

Sort by:
1 - 1 of 11
    User: "Baba_Majekodunmi_703"
    Altair Employee
    Updated by Baba_Majekodunmi_703

    Hi Shawn,

    Great question. I have made an attempt to simulate this. Here's what I did.

    1. I created a classic model to capture the data from the JSON file like a text file.
    2. I then used the data prep studio functions to clean it up to extract a unique identifier (in this case Account Number)
    3. Finally I joined the two tables together.

    Not sure if this is exactly what you're looking for, but I hope it at least gives you some ideas. I've attached the files a well as a reference.

    image