[xquery-talk] compare dayTimeDuration ?

Aaron Redalen Aaron.Redalen at marklogic.com
Sat Feb 24 10:26:41 PST 2007


Apologies if I've misunderstood your point, but the op functions are available to users via operators, are they not? 

For instance: 

op:date-greater-than($arg1 as xs:date, $arg2 as xs:date) as xs:boolean

Provides the implementation for an expression like:

(xs:date("2007-02-24") gt xs:date("1959-02-03"))

However, it probably could be made clearer to new users that op: functions are not designed to be called as functions, but using their corresponding operators.

Again, my apologies if I've misunderstood you in any way.

Sebastian, I suspect you just need to cast your values to xs:date.

Aaron Redalen
Staff Consultant
Mark Logic Corporation
+1 240 688 7433 Phone
Aaron.Redalen at marklogic.com
www.marklogic.com


-----Original Message-----
From: talk-bounces at x-query.com [mailto:talk-bounces at x-query.com] On Behalf Of Martin Probst
Sent: Friday, February 23, 2007 12:29 PM
To: Ilya Sterin
Cc: talk at xquery.com; Sébastien Geindre; Andrew Welch
Subject: Re: [xquery-talk] compare dayTimeDuration ?

> A simple look at the docs would of yielded the answer...
>
> http://www.w3.org/TR/xpath-functions/#durations-dates-times

I don't think this actually helps - the op:... functions are not  
available to users, and there is nothing else mentioned. Also, at  
least for me, I found that you need to read the regular XQuery spec,  
the F&O and the XML schema spec at the same time to find out the  
particular semantics of some operations. This is not something I  
would recommend or expect users to understand.

Regards,
Martin

-- 
Martin Probst
X-Hive Corporation
martin at x-hive.com


_______________________________________________
talk at x-query.com
http://x-query.com/mailman/listinfo/talk



More information about the talk mailing list