[xquery-talk] XQuery and the Rule of Least Power

Michael Rys mrys at microsoft.com
Tue Mar 7 07:38:06 PST 2006

Once you start using recursion it does "violate" it since you can get
non-terminating recursion. Without it you are fine.

Best regards

> -----Original Message-----
> From: talk-bounces at xquery.com [mailto:talk-bounces at xquery.com] On
> Of Jonathan Robie
> Sent: Tuesday, March 07, 2006 7:09 AM
> To: xquery-talk
> Subject: [xquery-talk] XQuery and the Rule of Least Power
> I just read the TAG finding called "The Rule of Least Power" [1], and
> find it difficult to know how to apply it to XQuery. The following
> statement is central to the paper:
> > The Turing-complete languages are shown by computer science to be
> > equivalent in their ability to compute any result of which a
> > is capable, and are in that sense the most powerful class of
> > for computers. The tradeoff for such power is that you typically
> > cannot determine what a program in a Turing-complete language will
> > without actually running it. Indeed, you often cannot tell in
> > whether such a program will even reach the point of producing useful
> > output.
> Although XQuery is Turing complete, all it can do is return values,
> if you have a static type system, you also know an awful lot about
> values it is going to return. Any thoughts on how this Rule applies to
> deciding whether to use XQuery for a given project? Or does XQuery
> violate the Rule proposed here?
> Jonathan
> [1] http://www.w3.org/2001/tag/doc/leastPower.html
> --
> Read my Blog: http://blogs.datadirect.com/jonathan_robie/
> Learn XQuery:
> http://media.datadirect.com/download/docs/ddxquery/tutorial_query.html
> Learn XQJ (the JDBC for XQuery):
> http://www.datadirect.com/developer/xquery/topics/xqj_tutorial/
> Get DataDirect XQuery: http://www.datadirect.com/products/xquery/
> _______________________________________________
> talk at xquery.com
> http://xquery.com/mailman/listinfo/talk

More information about the talk mailing list