W3C home > Mailing lists > Public > public-qt-comments@w3.org > October 2010

[Bug 11147] New: [XQuery11] The rule for rewriting nondeterministic function calls is too strict

From: <bugzilla@jessica.w3.org>
Date: Tue, 26 Oct 2010 14:21:35 +0000
To: public-qt-comments@w3.org
Message-ID: <bug-11147-523@http.www.w3.org/Bugs/Public/>

           Summary: [XQuery11] The rule for rewriting nondeterministic
                    function calls is too strict
           Product: XPath / XQuery / XSLT
           Version: Working drafts
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XQuery 1.1
        AssignedTo: jonathan.robie@redhat.com
        ReportedBy: josh.spiegel@oracle.com
         QAContact: public-qt-comments@w3.org
             Group: XSLXQuery_WG

The following statement is in section 4.18 Function Declaration:

"When rewriting expressions into equivalent expressions, as described in 2.3.4
Errors and Optimization, a conforming XQuery implementation must ensure that
each run-time invocation of a nondeterministic function in the original
expression results in exactly one run-time invocation of the function in the
rewritten expression."

This statement seems too strict.  An optimizer should be able to eliminate
nondeterministic function calls that do not contribute to the results of the

For example, consider this query:

let $x := f()

Even if f() is nondeterministic, it seems OK for an optimizer to rewrite this
expression as 27.  

Note, this issue has be discussed previously [1].  One suggestion was to change
the wording as follows [2]:

"If a non-deterministic function call contributes to the results of an
expression, a conforming XQuery implementation must ensure that every result is
generated by a new invocation of the function."

[1] http://lists.w3.org/Archives/Member/w3c-xsl-query/2010Jul/0169.html
[2] http://lists.w3.org/Archives/Member/w3c-xsl-query/2010Jul/0192.html

Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
Received on Tuesday, 26 October 2010 14:21:37 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:57:32 UTC