If I understand correctly...
<xsl:template match="transaction-list">
<dest-transaction-list total="total">
<xsl:for-each select="transaction/breakdown/@account">
<xsl:attribute name="{.}"><xsl:value="."/></xsl:attribute>
</xsl:for-each>
<xsl:for-each select="transaction">
<dest-transaction total="@total">
<xsl:for-each select="../transaction/breakdown/@account">
<xsl:attribute name="{.}">0</xsl:attribute>
</xsl:for-each>
<xsl:for-each select="breakdown">
<xsl:attribute name="{(_at_)account}"><xsl:value="@ammount"/></xsl:attribute>
</xsl:for-each>
</dest-transaction>
</xsl:for-each>
</dest-transaction-list>
untested..
David
_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service. For further
information visit http://www.star.net.uk/stats.asp or alternatively call
Star Internet for details on the Virus Scanning Service.
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list