Issues with XSL document function in Transformation on OSB
RuffSJun 6 2012 — edited Jun 11 2012I'm attempting to use the xsl document function in my XSLT file to perform a transformation on the Oracle Service Bus (version 11.1.1.4), but am seeing the following error when running the test from sbconsole (just testing the transformation currently).
Error executing the XSLT transformation: com.sun.org.apache.xalan.internal.xsltc.TransletException: com.sun.org.apache.xml.internal.utils.WrappedRuntimeException: Validation of XSLT Project1/xslt/iso-3-to-iso-2-lookup.xml : XSLT Project1/xslt/iso-3-to-iso-2-lookup.xml does not exist failed
The error is indicating the the XML file that I'm referencing from the XSLT does not exist in the folder specified, I have confirmed that this file does indeed exist and have tried moving it to other locations and chaning the reference location in the XSLT, but the error persists (with location updated). Does anyone know if the XSL document function is supported for transformations on the OSB or if there's something special that must be done so that OSB can reference the XML file properly?
Here's the code snippet from the xslt file which is calling using the XML file:
...
<xsl:output method="xml" encoding="UTF-8" indent="yes" omit-xml-declaration="yes"/>
<xsl:key name="ISO-3-to-ISO-2-lookup" match="country" use="iso3"/>
<xsl:variable name="ISO-3-to-ISO-2-Lookup" select="document('iso-3-to-iso-2-lookup.xml')/ISO-Countries"/>
<xsl:template match="/xx-xxxx:SyncSearchRequest">
<ns0:Search>
...
Here's a snippet from the XML file that I'm using as the lookup table:
...
?xml version="1.0"?>
<ISO-Countries>
<country><iso2>AF</iso2><iso3>AFG</iso3></country>
<country><iso2>AX</iso2><iso3>ALA</iso3></country>
<country><iso2>AL</iso2><iso3>ALB</iso3></country>
...
Thanks for any help.