Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
New Member

UCCX XPath on Get XML Document Data Step always returns null

Hello,

Can someone tell whats wrong with my XPath, because it always returns null. I have tried different variations and nothing. I'm using UCCX 7.0

XML

<?xml version="1.0" encoding="utf-8" ?>
<GetManagersResult xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.labdomain.com/">
  <ClaimManagersList>
    <X_CLAIM_MANAGER>
      <ClaimManagerUserName>test</ClaimManagerUserName>
    </X_CLAIM_MANAGER>
  </ClaimManagersList>
</GetManagersResult>

XPATH

"/descendant::GetManagersResult/child::ClaimManagersList/child::X_CLAIM_MANAGER/child::ClaimManagerUserName"

During debug, this is the value of the xml document when it reaches the Get XML Document Data step:

TEXT[<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n<GetManagersResult xmlns=\"http://www.labdomain.com/\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">\r\n  <ClaimManagersList>\r\n    <X_CLAIM_MANAGER>\r\n      <ClaimManagerUserName>test</ClaimManagerUserName>\r\n    </X_CLAIM_MANAGER>\r\n  </ClaimManagersList>\r\n</GetManagersResult>]

1 ACCEPTED SOLUTION

Accepted Solutions

Re: UCCX XPath on Get XML Document Data Step always returns null

It's your XML namespace in the root element.

First off, I have never seen the CRS Editor play nice when XML namespaces are involved.

Secondly, with your namespace in place, not even a generic xpath expression tester can find your data.  See attachements.

I think that if you find a way to either: not send, or remove the namespace from your document, your xpath expression will work.

With Namespaces

Without Namespaces


Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.
2 REPLIES

Re: UCCX XPath on Get XML Document Data Step always returns null

It's your XML namespace in the root element.

First off, I have never seen the CRS Editor play nice when XML namespaces are involved.

Secondly, with your namespace in place, not even a generic xpath expression tester can find your data.  See attachements.

I think that if you find a way to either: not send, or remove the namespace from your document, your xpath expression will work.

With Namespaces

Without Namespaces


Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.
New Member

Re: UCCX XPath on Get XML Document Data Step always returns null

Thanks Anthony.

The problem was the namespaces declarations.

988
Views
0
Helpful
2
Replies
CreatePlease to create content