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 10110 - [XQuery11UC]expected result sample for windowing question 2 seems wrong
Summary: [XQuery11UC]expected result sample for windowing question 2 seems wrong
Status: RESOLVED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XQuery 3.0 Use Cases (show other bugs)
Version: Working drafts
Hardware: PC Windows XP
: P2 normal
Target Milestone: ---
Assignee: Jonathan Robie
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL: http://www.w3.org/TR/xquery-11-use-ca...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-08 14:11 UTC by Martin Honnen
Modified: 2010-12-12 17:59 UTC (History)
0 users

See Also:


Attachments

Description Martin Honnen 2010-07-08 14:11:57 UTC
The input document for http://www.w3.org/TR/xquery-11-use-cases/#windowing_head_para is as follows:

<body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="head_para.xsd">
  <h2>heading1</h2>
  <p>para1</p>
  <p>para2</p>
  <h2>heading2</h2>
  <p>para3</p>
  <p>para4</p>
  <p>para5</p>
</body>

The expected result is as follows:

<chapter>
  <section title="heading1">
    <para>para1</para>
    <para>para2</para>
    <para>heading2</para>
  </section>
  <section title="heading2">
    <para>para3</para>
    <para>para4</para>
    <para>para5</para>
  </section>
</chapter>

Why does the "section" element with 'title="heading1"' have a third "para" element with contents "heading2"? 

With the English description of the aim being "Convert a structure with implicit sections to a structure with explicit sections." I would expect a result where each "section" elements wraps the "para" elements following the "h2" in the input:

<chapter>
  <section title="heading1">
    <para>para1</para>
    <para>para2</para>
  </section>
  <section title="heading2">
    <para>para3</para>
    <para>para4</para>
    <para>para5</para>
  </section>
</chapter>

That is also the result I get with Zorba 1.2.0 when using the code in http://www.w3.org/Bugs/Public/show_bug.cgi?id=6241 which seems to be a fix of the code sample in the public working draft.
Comment 1 Jonathan Robie 2010-12-12 17:59:33 UTC
The Working Group agrees. I will make the suggested change.