Subject: Re: [xsl] Adding a xs:yearMonthDuration to a xs:dateTime to obtain a new xs:dateTime variable From: Allan Kamau <kamauallan@xxxxxxxxx> Date: Mon, 16 Oct 2006 07:08:40 -0700 (PDT) |
Thanks Abel, it worked. Allan. --- Abel Braaksma <abel.online@xxxxxxxxx> wrote: > Allan Kamau wrote: > > > > I am using saxon8. > > If I use > > <xsl:variable name="tmp3" > > > select='$currentGridDate+xs:yearMonthDuration("P1M")'/> > > or > > <xsl:variable name="tmp3" as="xs:dateTime" > > > select='$currentGridDate+xs:yearMonthDuration("P1M")'/> > > > > The datetype of $tmp3 will be xs:dayTimeDuration > in > > both cases. > > I think that you should explicitly convert the first > argument to > xs:dateTime, or it must be explicitly declared. This > works, and returns > "2004-12-15T15:12:10" (which is 1 day and 1 hour > later than the supplied > date time): > > <xsl:value-of > select="xs:dateTime('2004-12-14T14:12:10') + > xs:dayTimeDuration('P1DT1H')"></xsl:value-of> > > I tried it with Saxon 8.8, newest release. > > Hth, > > Cheers, > -- Abel Braaksma > http://www.nuntia.com > > __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Adding a xs:yearMonthDura, Abel Braaksma | Thread | [xsl] Figure Problem using XSL-FO, Byomkesh |
Re: [xsl] Question about table colu, G. Ken Holman | Date | Re: [xsl] Figure Problem using XSL-, David Carlisle |
Month |