Login  Register

Re: Re: Re: Xpath fn:seconds-from-dateTime() not working

Posted by SD on Feb 18, 2011; 10:14pm
URL: https://discuss.orbeon.com/Xpath-fn-seconds-from-dateTime-not-working-tp3313272p3313618.html

Thanks a lot.

On Fri, Feb 18, 2011 at 2:31 PM, Florian Schmitt <[hidden email]> wrote:
ssethia,

> Thanks, it works but the return value is a huge integer (1289509005)

correct - that's what the xforms 1.1 seconds-from-dateTime should
return. It doesn't extract the seconds part of the dateTime value but
computes the seconds since 1970-01-01T00:00:00Z (1).

> also all the remaining functions {eg:
minutes-from-dateTime(xs:dateTime(time))}
> works smoothly except this one. Why is it so that the seconds-from-dateTime
> needs a string while the minutes-from-dateTime doesn't.

hmm - i'm not sure... regarding minutes-from-dateTime, there's no
XForms 1.1 function with the same name, so it seems that the XForms
functions take precedence if there's a name conflict, but the XPath
functions are still available. So, the next question would be how to
persuade the XForms processor to handle seconds-from-dateTime as XPath
function...

(1)
http://www.w3.org/TR/2009/REC-xforms-20091020/#fn-seconds-from-dateTime

florian


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws




--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws