On 12/06/14 01:40, Cindy A McMullen wrote:
Thanks, Andy.  We're trying to:

1. convert xsd:dateTime to timeInMsec

You'll need to add a custom function - you don't need to recompile ARQ,it already supports dynmica loading of custom functions.

2. do some simple multiplication/division

Surely multiplication and division only make sense on intervals of time (durations or, if you squint a bit, xsd:time).

The effects of multiplication and division on dates/dateTimes will depend on the choice of the epoch point.

        Andy


On Jun 11, 2014, at 12:04 PM, Andy Seaborne wrote:

On 11/06/14 17:44, Cindy A McMullen wrote:
Hi -

In a SPARQL query, is there a way to convert xsd:dateTime to 'time in
milliseconds' so that arithmetic operations are supported?  Or  must
we store the information as long (time in millisecs) to begin with?

Operations on xsd:dateTime are supported directly including durations (where it makes sense - 
see "XQuery 1.0 and XPath 2.0 Functions and Operators" (F&O) for details - only 
some durations are meaningful).

There is no conversion function provided to/from milliseconds (theer isn't in 
F&O) but you can add one as a custom function.

What are you trying to do?

        Andy


Thanks -

-- Cindy





Reply via email to