我需要XSLT 1.0中的帮助将以下源XML转换为结果XML。不太熟悉XSLT,并且同时在这个论坛中搜索有用的帖子。谢谢你的帮助。在XML转换中需要XSLT帮助
源XML:
<BomCollection>
<BomAssyV>
<sender>Oracle</sender>
<messageid>ABCD1234EFG</messageid>
<bomid>1234</bomid>
<partid>4567</partid>
<loc>DEL</loc>
<country>IND</country>
<cost>30</cost>
<linenumber>1</linenumber>
<componentpartid>CID1</componentpartid>
<componenttype>CTYPE</componenttype>
<quantityperpart>2</quantityperpart>
</BomAssyV>
<BomAssyV>
<sender>Oracle</sender>
<messageid>ABCD1234EFG</messageid>
<bomid>1234</bomid>
<partid>4567</partid>
<loc>DEL</loc>
<country>IND</country>
<cost>30</cost>
<linenumber>2</linenumber>
<componentpartid>CID2</componentpartid>
<componenttype>CTYPE</componenttype>
<quantityperpart>30</quantityperpart>
</BomAssyV>
<BomAssyV>
<sender>Oracle</sender>
<messageid>ABCD1236EFG</messageid>
<bomid>4321</bomid>
<partid>8901</partid>
<loc>MUM</loc>
<country>IND</country>
<cost>45000</cost>
<linenumber>1</linenumber>
<componentpartid>PID3</componentpartid>
<componenttype>PTYPE</componenttype>
<quantityperpart28></quantityperpart28>
</BomAssyV>
</BomCollection>
结果XML:
<request>
<sender>Oracle</sender>
<messageId>ABCD1234EFG</messageId>
<header>
<bomid>1234</bomid>
<partId>4567</partId>
<loc>DEL</loc>
<country>IND</country>
<cost>30</cost>
<line>
<lineNumber>1</lineNumber>
<componentPartId>CID1</componentPartId>
<componentType>CTYPE</componentType>
<quantityPerPart>2</quantityPerPart>
</line>
<line>
<lineNumber>2</lineNumber>
<componentPartId>CID2</componentPartId>
<componentType>CTYPE</componentType>
<quantityPerPart>30</quantityPerPart>
</line>
</header>
<header>
<bomid>4321</bomid>
<partId>8901</partId>
<loc>MUM</loc>
<country>IND</country>
<cost>45000</cost>
<line>
<lineNumber>1</lineNumber>
<componentPartId>PID3</componentPartId>
<componentType>PTYPE</componentType>
<quantityPerPart></quantityPerPart>
</line>
</header>
</request>
这个问题是一个位VA GUE。如果您在XSLT中寻找教程,那么Google可能是您的朋友。如果你有一些更具体的东西,我们很乐意提供帮助。 – Will
阅读w3c教程。但需要上述要求的帮助。需要将我的文章中给出的Source XML转换为Result XML。 – user1948230
这是一个非常直接的转变。请提供您当前的XSLT模板和具体问题,而不是仅仅让人们为您编写整个事件。 –