<?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>4972</bug_id>
          
          <creation_ts>2007-08-20 17:23:32 +0000</creation_ts>
          <short_desc>[FTUseCase] wrong scope usage in use case XQuery-XPath-Composability</short_desc>
          <delta_ts>2008-02-11 20:00:29 +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>Full Text 1.0</component>
          <version>Working drafts</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Windows XP</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</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="Chavdar Botev">cbotev</reporter>
          <assigned_to name="Pat Case">pcase</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>16229</commentid>
    <comment_count>0</comment_count>
    <who name="Chavdar Botev">cbotev</who>
    <bug_when>2007-08-20 17:23:32 +0000</bug_when>
    <thetext>See http://lists.w3.org/Archives/Member/member-query-fttf/2007Aug/0018.html

*5) Use Case XQuery-XPath-Composability *

Q2 Full-Text Query Returning Count of Descendant Element Occurrences
wrong scope usage: title is already out of scope
Suggestion: $title is bound in for, but second usage of $title is after the flowr

&lt;number-of-steps&gt;
{count($title/..//step)}
&lt;/number-of-steps&gt;

Q7 Full-Text Query with Date Comparison and Element Occurrence Count
wrong scope usage: in the predicates [] $book is not yet bound/in scope
Suggestion: replace $book in binding path with .

for $book in doc(&quot;FTTests/Files/sample_data.xml&quot;)
/books/book
[(($book/metadata/publicationInfo/dateIssued &gt; &quot;2000-12-31&quot;)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>16990</commentid>
    <comment_count>1</comment_count>
    <who name="Pat Case">pcase</who>
    <bug_when>2007-10-02 13:13:15 +0000</bug_when>
    <thetext>As Use Case editor I thank the submitters for this and other bugs submitted addressing the FT Use Cases. Your careful review is greatly appreciated. 

This bug has 2 parts:

1) This bug correctly states there is wrong scope usage: title is already out of scope. We have made the following modifications to the return statement for 16.2.2 Q2 Full-Text Query Returning Count of Descendant Element Occurrences:
return &lt;book number=&quot;{$book/@number}&quot;&gt; 
          {$book/metadata/title,
          for $title in $ct
          return 
             ($title, 
             &lt;number-of-steps&gt; 
                {count($title/..//step)}
             &lt;/number-of-steps&gt;)}
       &lt;/book&gt;

2) This bug correctly states that in the predicates [] $book is not yet bound/in scope and should be replaced with &quot;.&quot;. We have made the following modifications to the predicates in Q7 Full-Text Query with Date Comparison and Element Occurrence Count:
   [((./metadata/publicationInfo/dateIssued &gt; &quot;2000-12-31&quot;) 
   or (./metadata/publicationInfo/dateRevised &gt; &quot;2000-12-31&quot;)) 
   and count(./metadata/author) &gt; 1]

The Full Text Task Force agreed to modify the use cases as cited above. These modifications have been made in the October 1 internal version and will appear in the next public version. If the submitters agree with the modifications, please mark this bug closed.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>