The ProductRevision@id has a sequential number
and can occur multiple time. The transverseRootRefs should be a list of each sequential number that in productRevision@id.
After reading your last comment, I assumed the <xsl:for-each select="/PLMXML/ProductRevision/@id"> will pull each item from ProductRevision@id into the transverseRootRefs. I was wrong.
I know you gave me the syntax <xsl:for-each select="/eCrfs/eCrf/ProductRevision/@id"> but that did not make sense to me so i tried something different. Then I decided that I really do not know what I am doing and that I sould listen to you. But that didn't seem to work either. So that is the reason why I attached the xsl. I hope you could show me the errors of my ways.
Subject:No Topic Author:Alberto Massari Date:02 May 2008 10:52 AM
the mismatch in our conversation is caused by the fact that you are talking about an attribute created in the output, that cannot be accessed using XPath as it doesn't belong to the source tree (indeed, when you are creating the Header output element, the ProductRevision elements haven't been created yet, you cannot gather their ids).
You need to either:
1) write two stylesheets, where the first one creates the three Product, ProductRevision and Form element while the second one builds the Header using as input the output of the first, or
2) compute the three elements as the value of a single variable, and then build the Header by querying the variable, followed by a copy-of of the variable itself, or
3) duplicate the code that computes the id as part of the Header computation (e.g.
</xsl:attribute>) even if this means you could have problems in maintaining the two expression aligned