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 25703 - Example of xsl:merge still contains bind-key attribute
Summary: Example of xsl:merge still contains bind-key attribute
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XSLT 3.0 (show other bugs)
Version: Member-only Editors Drafts
Hardware: PC All
: P2 trivial
Target Milestone: ---
Assignee: Michael Kay
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-14 08:03 UTC by Innovimax
Modified: 2014-08-02 13:59 UTC (History)
0 users

See Also:


Attachments

Description Innovimax 2014-05-14 08:03:45 UTC
The example in 15.8 Examples of xsl:merge still make use of bind-key attribute

[[
<xsl:merge bind-key="merge-key">
  <xsl:merge-source name="master" 
                    select="doc('master.xml')/data/record">
      <xsl:merge-key select="@ID"/>
  </xsl:merge-source>
  <xsl:merge-source name="updates"
                    sort-before-merge="yes"
                    select="doc('transactions.xml')/transactions/update">     
      <xsl:merge-key select="@record"/>
  </xsl:merge-source>
  <xsl:merge-action>
    <xsl:choose>
      <xsl:when test="empty(current-merge-group('updates'))">
        <xsl:copy-of select="current-merge-group('master')"/>
      </xsl:when>
      <xsl:when test="current-merge-group('updates')/@action=('insert', 'replace')">
        <record ID="{$merge-key}">
          <xsl:copy-of select="current-merge-group('updates')/*"/>
        </record>
      </xsl:when>
      <xsl:when test="current-merge-group('updates')/@action='delete'"/>
    </xsl:choose>
  </xsl:merge-action>
  </xsl:merge>
]]
Comment 1 Michael Kay 2014-05-15 14:04:49 UTC
Thanks. Fixed editorially.