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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
bhagyarekha
Creator II
Creator II

xpath query for json file

Hi Talend Team,
I have json file and need to be inserted into mysql database.
so here am unable to fetch the data from one of the array.please help me out
Am using xpath query.
example
xyz:
here i need to get "abc" in one column and "def" in another column.am unable to write the Xpath for that one.
Appreciate for your response.
Regards,
rekha 
Labels (4)
2 Replies
avinashbasetty
Contributor III
Contributor III

Hi,
The json format you provided is incorrect. you can check this validator  https://jsonformatter.curiousconcept.com/
Once you checked it you can browse it from the JSON format available in the metadata where you can fetch the columns.
Valid JSON
{
"xyz":
{
"col1":,
"col2":
}
}
0683p000009MBs8.png
0683p000009MC5k.png
Regards,
Avinash.B
8885453419
Anonymous
Not applicable

Hi avinashbasetty, 
have you an idea how I can get the position of a data on a json file.
Example:
Input file
{
    "product":
    }]
}
resul wished:
 Product                      productPrice_position          name
12-0000027935            0                                  First Component MR Price
12-0000027935            1                                  First Component's OT price
thanks