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

Announcements
Streamlining user types in Qlik Cloud capacity-based subscriptions: Read the Details
cancel
Showing results for 
Search instead for 
Did you mean: 
DDcosta1619866252
Contributor
Contributor

Talend Mediation Check Xpath Value

Hi

I have an XML which has the below value.

I am using cMessageRouter to check for the value "NEW"

I also used

StringHandling.TRIM("/REQUEST/REQUEST_TYPE/text()").equals("NEW"), but it is not working.

Please tell me how to remove spaces to get it work?

My

REQUEST_TYPE

value has spaces

<?xml version="1.0" encoding="UTF-8" ?>

<REQUEST>

<REQUEST_TYPE>

  NEW

</REQUEST_TYPE>

</REQUEST>

0695b00000EbdtAAAR.png

0695b00000EbdsqAAB.png

Labels (3)
4 Replies
DDcosta1619866252
Contributor
Contributor
Author

@Xiaodi Shi​ I have posted a query which I am facing but no one is suggested or recommended. Can you please provide some suggestion

DDcosta1619866252
Contributor
Contributor
Author

Hi,

 

did anyone got a chance to look at my query

 

Thanks,

Dan

gjeremy1617088143

HI, i think your query is not good :

StringHandling.TRIM("/REQUEST/REQUEST_TYPE/text()").equals("NEW") will compare the String "/REQUEST/REQUEST_TYPE/text()" and not the /REQUEST/REQUEST_TYPE/text() value.

Send me Love and Kudos

gjeremy1617088143

maybe "//REQUEST/REQUEST_TYPE[contains(text(),'NEW')]"