This discussion is archived
0 Replies Latest reply: Jan 12, 2012 8:08 AM by user389718 RSS

OSB XSLT Transform in Service Orchestration

user389718 Newbie
Currently Being Moderated
I am trying to use the function op:subtract-dayTimeDuration-from-dateTime within a stylesheet within a stage in the OSB. Is it possible to use this function in a stylesheet? I get an error after using the test console to test the XSLT resource:
Error executing the XSLT transformation: java.lang.NoSuchMethodException: For extension function, could not find method java.lang.String.dateTime([ExpressionContext,] ).

Here is the relevant part of the stylesheet:
<?xml version="1.0"?>
<xsl:stylesheet version="2.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:op="http://www.w3.org/TR/xpath-functions"
xmlns:xdt="http://www.w3.org/TR/xpath-datatypes"
xmlns:xf="http://www.w3.org/TR/xquery-operators"
xmlns:xs="http://www.w3.org/2001/XMLSchema" >
               <timeframe>
                    <begin>
<xsl:variable name="now" select="op:subtract-dayTimeDuration-from-dateTime(xs:dateTime('2003-01-02T01:01:00'), xf:dayTimeDuration('P1DT1M'))" />
<xsl:value-of select="$now" />
                    </begin>
               </timeframe>
</xsl:stylesheet>

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points