xml - Oracle XSL processor expanding namespaces -
i generating , validating xml , experiencing problem oracle expands full namespace prefix. source document may this:
<pcy> <tlist> <currtrn> <txn_a>1</txn_a> <txn_b>2</txn_b> ...
the transform looks this:
<?xml version="1.0" encoding="utf-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/xsl/transform" xmlns:sc="http://www.mycompany.com/schemaalpha" xmlns:pl="http://www.mycompany.com/schemabeta"> <xsl:template match="/"> <pcyitem> <pl:maintlist> <pl:currenttrnitem> <sc:primarytrnid> <xsl:value-of select="/pcy/tlist/currtrn/txn_a"/> </sc:primarytrnid> <sc:secondarytrnid> <xsl:value-of select="/pcy/tlist/currtrn/txn_b"/> </sc:secondarytrnid> ...
the correct output expect (and when use programs jedit - has xml transform plugin) looks this:
<?xml version="1.0" encoding="utf-8"?> <pcyitem xmlns:pl="http://www.mycompany.com/schemaalpha" xmlns:sc="http://www.mycompany.com/schemabeta"> <pl:maintlist> <pl:currenttrnitem> <sc:primarytrnid>1</scom:primarytrnid> <sc:secondarytrnid>2</scom:secondarytrnid> ...
what oracle produces looks this:
<pcyitem> <pl:maintlist xmlns:pl="http://www.mycompany.com/schemaalpha"> <pl:currenttrnitem> <sc:primarytrnid xmlns:sc="http://www.mycompany.com/schemabeta">1</sc:primarytrnid> <sc:secondarytrnid xmlns:sc="http://www.mycompany.com/schemabeta">2</sc:secondarytrnid> ...
it looks me oracle "inlining" or expanding of namespace prefixes. why doing , how can stop?
just guessing looks oracle implicitly sets
exclude-result-prefixes="pl sc"
i try setting
exclude-result-prefixes="#default"
to override possible implicit exclude.
Comments
Post a Comment