简体   繁体   中英

XSLT 2.0 and JDeveloper 11g

I'm doing transformation in Java and below is my XSL file

<?xml version="1.0" encoding="UTF-8" ?>
<xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<!-- Root template -->
<xsl:template match="/">
<Country>
<xsl:for-each-group select="/Country" group-by="City">
<City><xsl:value-of select="City"/></City>
</xsl:for-each-group>
</Country>
</xsl:template>
</xsl:stylesheet>

I got the below error

javax.xml.transform.TransformerException: java.lang.RuntimeException: Unsupported XSL element 'http://www.w3.org/1999/XSL/Transform:for-each-group' at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:716) at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:313)

I'm using JDeveloper 11.1.1.5 and the Java JDK that comes with it.

Does JDeveloper 11g support XSLT 2.0? If not how can we add XSLT 2.0 support into it?

Thank you

通过 Java,您可以使用 Saxon 9(可从http://sourceforge.net/projects/saxon/files/获得开源版本)来使用 XSLT 2.0。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM