<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>2289</bug_id>
          
          <creation_ts>2005-09-22 16:44:16 +0000</creation_ts>
          <short_desc>[xqueryx]  base uri (and other aspects of the initial context)</short_desc>
          <delta_ts>2005-09-29 11:56:21 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>XPath / XQuery / XSLT</product>
          <component>XQueryX 1.0</component>
          <version>Last Call drafts</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Windows XP</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>WONTFIX</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="David Carlisle">davidc</reporter>
          <assigned_to name="Jim Melton">jim.melton</assigned_to>
          
          
          <qa_contact name="Mailing list for public feedback on specs from XSL and XML Query WGs">public-qt-comments</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>6413</commentid>
    <comment_count>0</comment_count>
    <who name="David Carlisle">davidc</who>
    <bug_when>2005-09-22 16:44:17 +0000</bug_when>
    <thetext>The XQueryX specification needs to define parts of the execution environment
that are not determined by the stylesheet translation to XQuery.

For example what is the meaning of:

&lt;xqx:functionCallExpr&gt;
    &lt;xqx:functionName&gt;doc&lt;/xqx:functionName&gt;
    &lt;xqx:arguments&gt;
      &lt;xqx:stringConstantExpr&gt;
      &lt;xqx:value&gt;bib.xml&lt;/xqx:value&gt;
     &lt;/xqx:stringConstantExpr&gt;
    &lt;/xqx:arguments&gt;
&lt;/xqx:functionCallExpr&gt;

The semanics are defined by its translation by the stylesheet, to
doc(&quot;bib.xml&quot;)
but the meaning of that expression depends on the base URI in the initial
context in which this XQuery is evaluated, and that is currently undefined.

XQueryX should specify some constraints that say that the evaluation of the
XQueryX should be equivalent to execution of the generated XQuery with a static
context that is derived from that of the XQuery document (for example it has the
same base URI)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>6584</commentid>
    <comment_count>1</comment_count>
    <who name="Jim Melton">jim.melton</who>
    <bug_when>2005-09-29 09:36:09 +0000</bug_when>
    <thetext>The Working Group discussed this comment at length.  Once we understood the
relationships between the XML syntax and the human-readable syntax for XQuery,
we recalled that it has always been our intent for the two syntaxes to have
equivalent semantics.  One important consequence of this is that the XQuery
static context to which you refer is exactly the same static context that an
XQueryX engine would use.  That is, the fact that a different syntax is used
does not mean that the evaluation/execution engine behaves any differently
(other than the nature of the parser, of course). 

Therefore, we conclude that no change to the XQueryX document is needed or
justifiable. 

Please let us know if you agree with this resolution of your issue, by adding a
comment to the issue record and changing the Status of the issue to Closed. Or,
if you do not agree with this resolution, please add a comment explaining why.
If you wish to appeal the WG&apos;s decision to the Director, then also change the
Status of the record to Reopened. If you wish to record your dissent, but do not
wish to appeal the decision to the Director, then change the Status of the
record to Closed. If we do not hear from you in the next two weeks, we will
assume you agree with the WG decision.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>6601</commentid>
    <comment_count>2</comment_count>
    <who name="David Carlisle">davidc</who>
    <bug_when>2005-09-29 11:14:47 +0000</bug_when>
    <thetext>  The Working Group discussed this comment at length.  Once we understood the
  relationships between the XML syntax and the human-readable syntax for XQuery,
  we recalled that it has always been our intent for the two syntaxes to have
  equivalent semantics. 

If it takes the WG considerable time to remind themselves of this conclusion,
how is anyone else supposed to _ever_ come to this conclusion?

What is the objection to adding this paragraph

&gt; one important consequence of this is that the XQuery
&gt; static context to which you refer is exactly the same static context that an
&gt; XQueryX engine would use.  

to the xqueryx spec?

My current XqueryX evaluator works by 
a) running the stylesheet from the spec, writing the Xquery to a temporary file
b) executing the Xquery in an Xquery engine.

This works most of the time (including I think all of the current test suite)
but fails on (the xqueryx equivalent of) the Query

base-uri(&lt;a/&gt;)

which the above paragraph makes clear should return the URI of the XQueryX
document, but my system currently returns the URI of the temporary file.

This is an essentially editorial matter, just requesting that the WG&apos;s intention
is stated in the document, as it is certainly not at all easy to come to that
conclusion currently. 

David</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>6607</commentid>
    <comment_count>3</comment_count>
    <who name="Jim Melton">jim.melton</who>
    <bug_when>2005-09-29 11:44:39 +0000</bug_when>
    <thetext>Your point is well taken.  We will add a (non-normative) note giving the reader
of the XQueryX spec notice that the static environment for XQueryX is the same
as for XQuery. 

I am leaving the resolution as it is, even though we are making this change,
because I prefer not to re-open the bug only to intantly close it.  However, if
you want it marked differently, please let me know offline and I&apos;ll do so. 

Please let us know if you agree with this resolution of your issue, by adding a
comment to the issue record and changing the Status of the issue to Closed. Or,
if you do not agree with this resolution, please add a comment explaining why.
If you wish to appeal the WG&apos;s decision to the Director, then also change the
Status of the record to Reopened. If you wish to record your dissent, but do not
wish to appeal the decision to the Director, then change the Status of the
record to Closed. If we do not hear from you in the next two weeks, we will
assume you agree with the WG decision.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>6608</commentid>
    <comment_count>4</comment_count>
    <who name="David Carlisle">davidc</who>
    <bug_when>2005-09-29 11:56:21 +0000</bug_when>
    <thetext>Thanks for your final note confirming a note will be added to the spec, this is
an entirely satisfactory outcome, so I&apos;m closing this (which means I&apos;ve closed
all the xqx reports I had open, I hope I didn&apos;t eat up too much of your F2F time...)</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>