tExtractXMLField Xpath Query value

One Star

tExtractXMLField Xpath Query value

Below is the XML I am receiving from a webservice.
<root>
<success>true</success>
<message></message>
<access_token>1234567</access_token>
<profile/></root>

I want to extract access_token.  I tried few different options but I am not getting the right result. Here is how it looks currently:

Loop Xpath Query : /       
Xpath Query: /root/access_token
XML field: body  

Given the above XML structure, what is the right Xpath Query should I use in order to get the value of access_id?

Thank you for your help.

Arvind.

One Star

Re: tExtractXMLField Xpath Query value

resolved it myself. I used //root as the Loop Xpath Query and access_token as the field mapping which took care of it. 

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

Agile Data lakes & Analytics

Accelerate your data lake projects with an agile approach

Watch