I would need the help in XSLT 1.0 to transform the following Source XML to Result XML. Not very acquainted with XSLT and also searching for the useful posts in this forum simultaneously. thanks for your help.
Source 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>
Result 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>