ESB: xsl-import
Hello
How can I use the xsl-import with the ESB?
It seems I have to give a absolute url in xsl-import, like this:
<xsl:import href="http://myserver/extra.xsl"/>
The following will not work:
<xsl:import href="extra.xsl"/>
Can I do anything about it?
I found a solution in this post.
Re: xsl:import or xsl:include for ESB projects ?
But is there a better way?
Similar Messages
-
Xsl:import or xsl:include for ESB projects ?
I have an XSLT stylesheet transformer in a routing service on the ESB, and it uses an <xsl:import> of another stylesheet. I have forced the auxiliary stylesheet into the project zip for deployment alongside the main stylesheet, but the XSLT engine cannot resolve the imported file, the error is either:
"No protocol" if I just use "foo.xsl"
"FileNotFound if I try "file:foo.xsl"
The XSLT engine should import a relative URI wrt the main stylesheet, but it appears it cannot handle relative URIs, and what it's really expecting is a file: or classpath: protocol.
Any ideas what URI incantation I need for it to locate the imported stylesheet ?
MikA bit of reverse engineering of the error message, reveals the shocking fact that I have to use this URI:
<xsl:import href="esb:///ESB_Projects/MyProject_esb/foo.xsl" />
So the stylesheets have to be modified from the original form used outside the ESB, and even changed depending on the project which contains them !
Please tell me there's a better way ?
Mik -
Using xsl:import and trying to access a variable defined in another xsl
Hi
I am having a a.xsl file with contents liek this :
<xsl:variable name="PersonId" select="'1910'"/>
inside b.xsl i am importing a.xsl like
<xsl:import href="a.xsl"/>
<xsl:value-of select="$PersonId"/>
This is working fine when i am testing it standalone.
when i port the code to weblogic server (meaning when all the
project related files are placed in proper location in
weblogic) and start the application then i get the error msg :
xsl:1031 variable not defined 'PersonId'.
i tried giving the enite path like :http://localhost:7001/....
even then problem remains unresolved.
am i making any mistake ?
Thank you
Regards
JayaThis works fine for me with Oracle XSL Processor 9.0.2C
<!-- a.xsl -->
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:variable name="PersonId" select="1910"/>
</xsl:stylesheet>and
<!-- b.xsl -->
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:import href="a.xsl"/>
<xsl:template match="/">
<xsl:value-of select="$PersonId"/>
</xsl:template>
</xsl:stylesheet>Make sure you're using the latest version of the XDK in your
weblogic environment. -
Xsl:import in XSL templates
Hi,
I have BIP version 5.6.3 in EBS.
I have an XSL-TEXT template and I would like to use the <xsl:import> statement to import subtemplates.
So I do:
<xsl:import href="http://myapps.xxx.yy:8000/OA_MEDIA/my_subtemplate.xsl"/>This works pretty well, if I place my template file in the $OA_MEDIA folder on my APPS server.
BUT: This is using an absolute path to my server (myapps.xxx.yy:8000 in this case). For my development environments this absolute path is different of course.
So my question:
Does anybody know how to refer to my subtemplates by relative paths, or to construct an xsl:import statement that allows to have different paths based on the environment that I am currently working on?
Thanks,
David.Hi,
well, the templates are always in the same path on the server, they are all either uploaded to Template Manager in BIP or stored in $OA_MEDIA.
But the server name is different of course.
Oracle has implemented a nice feature to reference to subtemples in RTF templates, would be nice if one could do the same in XSLT.
Thanks,
David. -
XSL transformation with xsl:import generates exceptions
I am using the Schematron's basic XSL file basic-schematron.xsl to validate the XML format of one of our data files. The XSL file looks something like this
================
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:axsl="http://www.w3.org/1999/XSL/TransformAlias">
<xsl:import href="skeleton1-5.xsl"/>
<xsl:template name="process-prolog">
<axsl:output method="text" />
</xsl:template>
==================
But, the validation fails while trying to run the transformation on my Schematron input file using this basic-schematron.xsl with java.lang.NoSuchMethodError:
======= OUTPUT ============
Markup Error: no match attribute on <key> outside <rule>
Exception in thread "AWT-EventQueue-0" java.lang.NoSuchMethodError: GregorSamsa.process$dash$root(Lcom/sun/org/apache/xalan/internal/xsltc/DOM;Lcom/sun/org/apache/xml/internal/dtm/DTMAxisIterator;Lcom/sun/org/apache/xml/internal/serializer/SerializationHandler;ILjava/lang/Object;)V
at GregorSamsa.applyTemplates()
at GregorSamsa.applyTemplates()
at GregorSamsa.transform()
at com.sun.org.apache.xalan.internal.xsltc.runtime.AbstractTranslet.transform(AbstractTranslet.java:594)
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:640)
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:279)
at com.solipsa.xsdvalidator.XSDValidator.validateSchematron(XSDValidator.java:137)
at com.solipsa.xsdvalidator.XSDValidator.validate(XSDValidator.java:181)
at com.solipsa.xsdvalidator.XSDValidatorUI.jButton1ActionPerformed(XSDValidatorUI.java:244)
at com.solipsa.xsdvalidator.XSDValidatorUI.access$300(XSDValidatorUI.java:21)
at com.solipsa.xsdvalidator.XSDValidatorUI$4.actionPerformed(XSDValidatorUI.java:140)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:234)
at java.awt.Component.processMouseEvent(Component.java:5488)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3093)
at java.awt.Component.processEvent(Component.java:5253)
at java.awt.Container.processEvent(Container.java:1966)
at java.awt.Component.dispatchEventImpl(Component.java:3955)
at java.awt.Container.dispatchEventImpl(Container.java:2024)
at java.awt.Component.dispatchEvent(Component.java:3803)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4212)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3892)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3822)
at java.awt.Container.dispatchEventImpl(Container.java:2010)
at java.awt.Window.dispatchEventImpl(Window.java:1766)
at java.awt.Component.dispatchEvent(Component.java:3803)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
============= OUTPUT ==============
I tried the individual JAXP 1.3 for J2SDK 1.4.2 (Using the -Djava.endorsed.dirs JVM param) and tried the JDK 1.5.0_02 which has JAXP 1.3 inbuilt and they all fail.
I tried the above with separate Xalan/Xerces jar files, and then it works fine.
The problem seems to be somthing specific to the JAXP 1.3 environment. I can provide more details, if required. Any help is highly appreciated.One morning your code woke up and found it had been transformed into a giant insect.
But seriously, here's the name of the method that doesn't exist:GregorSamsa.process$dash$rootIs GregorSamsa your class? Maybe your server has an old version of it which is missing that method? (Or: those $ signs look strange to me, maybe they are a mistranslation of some other character?) -
Xsl:import and xsl:call-template errors for xslt in mediator (ORAMED-03601)
Hello,
I decided for performance issues with bpel execution to use a mediator instead.
In my requester i have a mediator that justs recieves an xml message, uses an xsl transformation (version 2) on that message and then sends it to the EBS.
The xsl file that's works correctly when used in a bpel process has both <xsl:import..../>and <xsl:call_template.../> tags.
When i tried and used the same xsl in the mediator i get an ORAMED-03601 error:
ORAMED-03601:[Invalid transformer configuration]Unable to create transformer. It could be because of transformation file or configuration issues. Reason : "xsl/Xform_PriceListListABMReqMsg_to_PriceListEBMReqMsg.xsl"Possible Fix:Check log file for any exceptions and contact Oracle Support Services for further help
It works correctly again if i comment/remove all the imports and call-template and incorporate them in the xsl file itself.
Do anyone know if there are some limitations using xsl in a mediator instead of a bpel?Hi,
I have a problem with call-template. I have passed
sed some parameter with call-template tag and used
that parameter in the conditional check tag <xsl:if>
i am getting the error. Can any body tell how to use
this? I actuall want to dynamically pass the tag name
as the parameter and check the attribute value of the
tag passed in the if condition and then i want to
person some action. How can i do it?
Here is the call-template code:
<xsl:call-template name="selected-unselected">
<xsl:with-param
ram name="currentTag">motor-carrier</xsl:with-param>
</xsl:call-template>
Here is the template definition:
<xsl:template name="selected-unselected">
<xsl:param
m name="currentTag">Quick-Quote</xsl:param>
<xsl:if test="./{$currentTag}/@selected='true'">
<xsl:text>checked</xsl:text>
</xsl:if>
<xsl:if test="./{$currentTag}/@selected='false'">
<xsl:text>Unchecked</xsl:text>
</xsl:if>
</xsl:template>
Here is the sample xml code:
<motor-carrier selected="true"/>
<motor-truck selected="false"/>
<sched-mobile-equip selected="false"/>
Here instead of writing the condition check for every
tag i want to write it once and dynamically pass the
tag name as parameter to the template. If the
attribute of the tag has value true then one message
should be displayed otherwise a different message
should be displayed.try this:
<xsl:template name="selected-unselected">
<xsl:paramm name="currentTag">Quick-Quote</xsl:param>
<xsl:if test="./*[name()=$currentTag]/@selected='true'">
<xsl:text>checked</xsl:text>
</xsl:if>
<xsl:if test="./*[name()=$currentTag]/@selected='false'">
<xsl:text>Unchecked</xsl:text>
</xsl:if>
</xsl:template> -
Xsl:include xsl:import and clob
I can use xslprocessor.processXSL to perform transformation where the XML and XSL are in CLOBs.
However, is it possible to perform transformation if the XML and XSLs are in CLOBs and the XSL have xsl:include and xsl:import?
Thanks and Regards,
AndyIt will be supported in later release.
-
Why oracle xmlparserv2 dosen't support <xsl:import href="b.xsl"/>?
What's the error message mean?
"oracle.xml.parser.v2.XMLParseException: Error while processing include XSL file (b.xsl).
at oracle.xml.parser.v2.XMLError.flushErrors1(XMLError.java:205)......
It's working at Xalan or Saxon but not Oracle!I think the error message is telling you that the visual design surface that simplifies creating transforms doesn't support the <xsl:import>. If you need to use <xsl:import>, and assuming that <xsl:include> (which is quite similar to import) is also not supported, then the only other option is working on the XSLT stylesheet in the source editor.
-
Xsl:import and precedence?
I am following Steve's example on using "ColumnOverrides.xsl"
(page 700) to create drill down links for certain values I'm
returning. Problem is, my generic:
<xsl:template match="ROW/*">
<td valign="top"><xsl:apply-templates/></td>
</xsl:template>
...seems to be taking precedence over the templates I am
<xsl:import>ing:
<xsl:template match="ROW/Team">
<td>
<xsl:apply-templates/>
</td>
</xsl:template>
<xsl:template match="ROW/League">
<td>
<xsl:apply-templates/>
</td>
</xsl:template>
The ROW/Team and ROW/League returned values are not in hyperlink
form.
I can verify that the import is working by changing the ROW/*
template to specify ROW/Team. When I do that, the value for team
remains normal/un-hyperlinked, but the value for ROW/League is
now the correct hyperlink! So, that leads me to believe that the
ROW/* is taking precedence over the ROW/Team and ROW/League
imports.
Steve's book says to use xsl:import to make sure imported
templates take higher predcedence. Am I missing something?
Thanks. Excuse my lenghtly post.I figured it out. The <xsl:import>'s have to be in a particular
order as well. -
Using xsl:import in Weblogic
All,
I have a requirement to import an XSL template into another XSL template and use one of the methods defined in the imported file into this importing file. The problem is that it works perfectly fine if I do this in XMLSPY .. but if I do this thru weblogic it throws me an error and doesnot perform the action.
Would appreciate if someone could suggest what I can do to solve this problem.
Thanks ,
AdarshThis works fine for me with Oracle XSL Processor 9.0.2C
<!-- a.xsl -->
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:variable name="PersonId" select="1910"/>
</xsl:stylesheet>and
<!-- b.xsl -->
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:import href="a.xsl"/>
<xsl:template match="/">
<xsl:value-of select="$PersonId"/>
</xsl:template>
</xsl:stylesheet>Make sure you're using the latest version of the XDK in your
weblogic environment. -
DBMS_XSLPROCESSOR and xsl:import
Hi all!
I'm using Oracle 9.2 and DBMS_XSLPROCESSOR to transform my XML to HTML.
I build XML using DBMS_XMLDOM methods, build stylesheet using dbms_xslprocessor.newstylesheet,
then try to transform it using DBMS_XSLPROCESSOR.processXSL.
It work fine. But if I add <xsl:import href="http://server/myPackage.getXSL"/>
(myPackage.getXSL return another XSL) to my original xsl file, then dbms_xslprocessor.newstylesheet
function fails with error:
[1]: (Error): ORA-31011: XML parsing failed ORA-19202: Error occurred in XML processing LPX-00412:
Message 412 not found; product=XDK; facility=LPX ORA-06512: at "XDB.DBMS_XSLPROCESSOR",
line 467 ORA-06512: at "XDB.DBMS_XSLPROCESSOR" ...
Does anybody have any ideas what is wrong ?
Thanks in advance,
Gregory.Hi all!
I'm using Oracle 9.2 and DBMS_XSLPROCESSOR to transform my XML to HTML.
I build XML using DBMS_XMLDOM methods, build stylesheet using dbms_xslprocessor.newstylesheet,
then try to transform it using DBMS_XSLPROCESSOR.processXSL.
It work fine. But if I add <xsl:import href="http://server/myPackage.getXSL"/>
(myPackage.getXSL return another XSL) to my original xsl file, then dbms_xslprocessor.newstylesheet
function fails with error:
[1]: (Error): ORA-31011: XML parsing failed ORA-19202: Error occurred in XML processing LPX-00412:
Message 412 not found; product=XDK; facility=LPX ORA-06512: at "XDB.DBMS_XSLPROCESSOR",
line 467 ORA-06512: at "XDB.DBMS_XSLPROCESSOR" ...
Does anybody have any ideas what is wrong ?
Thanks in advance,
Gregory. -
How to resolve Error: "xsl:import" XSL Element Currently not Supported
Hello Everyone,
I have a xsl in my process to perform transformation of source schema to target schema.
This xsl is importing another xsl.
I am using <xsl:import> for this purpose.
But when I try to see the "design" editor I am getting the error given below:
Error: "xsl:import" XSL Element Currently not Supported
In "source" editor JDeveloper is giving no error.
I request you all to please come forward for the rescue ;-)
Thanks in advance.
Regards,
ShantyI think the error message is telling you that the visual design surface that simplifies creating transforms doesn't support the <xsl:import>. If you need to use <xsl:import>, and assuming that <xsl:include> (which is quite similar to import) is also not supported, then the only other option is working on the XSLT stylesheet in the source editor.
-
XSL:Import causing End-Of-Communication error when called in PL/SQL.
I have master xsl. I am importing another xsl in it. when I use xslTransform in my pl/sql stored procedure I receive end of communication error. I have used "file://" and "http://" both in xsl:import.
Here's the import lines:
<xsl:import href="file://D:/temp/Xsd/CommonFunctions.xsl"/>
or
<xsl:import href="http://www.v-tek.com/xsl/CommonFunctions.xsl"/>
I am not sure what causes this error. I tested this in xmlspy and it works well.Hi Justin,
I tried to reproduce your complaint, but wasnt able to. I didnt have a 10104 db to test against though, but I did test against 10105, and 10202, using the following dumb table:
create table constr_test ( c1 number);
alter table constr_test add constraint const_1 check (c1 in (1,2,null));
insert into constr_test values (3);
commit;
Frequently a 3113 is the result of an ora-600 or ora-7445 on the database. The fact that it doesnt occur for you on 10.2 db leads me to believe that might be the case here. Have you checked your alert logs?
Cheers,
Greg -
Not able to use xsl:import in my XSL doc
Hi,
I'm using Oracle 9.2.0.6.0 and DBMS_XSLPROCESSOR to transform my XML.
I build XML using DBMS_XMLDOM methods, build stylesheet using dbms_xslprocessor.newstylesheet,
then try to transform it using DBMS_XSLPROCESSOR.processXSL.
It work fine. But if I add <xsl:import href="new_file.xsl"/> to my original xsl file, then dbms_xslprocessor.newstylesheet
function fails with error:
[1]: (Error): ORA-31011: XML parsing failed ORA-19202: Error occurred in XML processing LPX-00412:
Message 412 not found; product=XDK; facility=LPX ORA-06512: at "XDB.DBMS_XSLPROCESSOR",
line 467 ORA-06512: at "XDB.DBMS_XSLPROCESSOR" ...
Any ideas??
Thanks in advance
FredOne idea. Do you have the namespace for the new_file.xsl defined?
-
Problem with xsl:import and xsl:apply-templates select="element_name"
I import a xsl tranformation into another xsl file.
During the transformation i want to limit the transformation to certain xml elements using the select attribute in apply-templates. However if I want restrict to xml elements whose templates are defined in the imported file, they will not be called.
I'm using currently JWSDP1.4 but problem was also with 1.3.
Can anybody help: Is this not xslt spec compliant or just a bug inXALAN ?
regards pszawlowSolved it by myself:
the problem was not the import but the following:
xml file: looks like:
<a>
<b>
</b>
<c>
</c>
</a>xsl file looked like and should omit output of <c> </c>:
<xsl:template match="/">
<xsl:apply-templates select="b" />
</xsl:template>
<xsl:template match="b">
</xsl:template>
However / is not the level <a>, which I thought. So there was no matching <b>.
I changed the xsl file to:
<xsl:template match="/">
<xsl:apply-templates />
</xsl:template>
<xsl:template match="a">
<xsl:apply-templates select="b" />
</xsl:template>
<xsl:template match="b">
</xsl:template>
and it worked !
Maybe you are looking for
-
Contacts and calendar on the phone are gone. How can I get them back?
I have sync my iphone with google contacts and now the pre-existing data, contacts and calendar entrys are missing on the phone. The contacts from google contacts are there but none of existing contacts and dates. Can I get them back? or are they g
-
When I try to open FF4 I get the message it can't be opened because it is not supported on my architecture. I can't believe no-one else has had this problem. You must have a lot of internet duffers who don't really know what they're doing. I need to
-
Import failure and temporary files
Hi, I'm trying to import my photos from my iPhone into Aperture using the Import function. During the import process, it creates a temporary file, like "..importing.IMG1721.JPG" onto my photo folder, and then continues to say "Importing" indefinitely
-
Disable embedded closed captions from video Asset?
Hello all, I have imported a H.264 file from Apple Compressor with embedded closed captions (not hardcoded I believe). Is it possible to disable them? The automatic formatting of the captions is not suitable, and I would like to use the native Encore
-
I paid for the Mountain Lion, was downloading perfect. When almost 1 gb of downloading was left then this error occured "The product distribution file could not be verified. It may be damaged or was not signed." and stopped downloading and now every