Quantcast
Channel: OutSystems Community
Viewing all articles
Browse latest Browse all 1476385

[Forums] Xml import actions are not working with namespaces

$
0
0
Hi Suraj,

I believe your problem is not related to the extension or OutSystems, but with the XPath standard itself and it behavior when using XML namespaces.

Basically the XPath query needs to be change to take into consideration the use of namespaces.

Take a look into this simple example:

<Fields>
          <Field>MyValue</Field>
</Fields>

If I select XPath /Fields/Field/text() it will return "MyValue" as expected.

If I use the a XML with namespace:

<Fields xmlns="x">
          <Field>MyValue</Field>
</Fields>

The previous query returns no results, however if you use this one you get the same result, even on a scenario where the xml uses a namespace:

/*[namespace-uri()='x' and local-name()='Fields']/*[namespace-uri()='x' and local-name()='Field']/text()

Hope it helps


Viewing all articles
Browse latest Browse all 1476385

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>