This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 5832 - wrong solution in xquery full text use case doc section 11.2.2
Summary: wrong solution in xquery full text use case doc section 11.2.2
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: Full Text 1.0 Use Cases (show other bugs)
Version: Working drafts
Hardware: All All
: P2 normal
Target Milestone: ---
Assignee: Pat Case
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-07-03 17:53 UTC by zhen hua liu
Modified: 2011-01-07 00:08 UTC (History)
2 users (show)

See Also:


Attachments

Description zhen hua liu 2008-07-03 17:53:40 UTC
In http://www.w3.org/TR/xmlquery-full-text-use-cases/#cardinality-queries-results-q2  (W3C Working Draft 16 May 2008)

for $book in doc("http://bstore1.example.com/full-text.xml")
   /books/book                        
let $subj := $book/metadata/subjects/subject            
where (some $s1 in $subj satisfies $subj ftcontains "web site")    
   and (some $s2 in $subj satisfies $subj ftcontains "usability")
return $book

This solution is NOT correct, the inner some clauses should use $s1 and $2, the correct solution is below:

for $book in doc("http://bstore1.example.com/full-text.xml")
   /books/book                        
let $subj := $book/metadata/subjects/subject            
where (some $s1 in $subj satisfies $s1 ftcontains "web site")    
   and (some $s2 in $subj satisfies $s2 ftcontains "usability")
return $book
Comment 1 Pat Case 2008-07-07 17:13:01 UTC
Zhen, I agree that the XQuery solution for 11.2.2 is incorrect and will correct it with your solution if I do not hear any objections.
Comment 2 Pat Case 2008-07-16 15:34:35 UTC
Zhen,

I handled this as editorial.

I corrected use of $s1 and $s2 variables in the XQuery and XPath solutions.

The correction will appear internally after the next use cases build. I will
send the FTTF an alert when it is ready. 

Please review and if you agree with the change, close the bug.

Pat