XSL - create well formed xml from text file
问题 I have a pipe delimited text file as shown below, which I need to transform into a well formed xml structure (example shown below) using xsl. The xsl below is my (latest) attempt at solving this - however I cannot seem to find a way to encapsulate the level 002 elements in level 001, i.e. maintain the parent-child relationship, when iterating through the file line by line. Could anyone help here ? Pipe delimited file - input 001|XXX|YYY 002|AAA|BBB 002|CCC|DD 001|EEF|XXX 002|HHH|GGG XML File