XSL to show parent as columns, with matching children as rows

后端 未结 1 1690
耶瑟儿~
耶瑟儿~ 2021-01-28 12:13

I am new to XML and XSL. I am trying to take a XML strings generated by our vendor software and translate it into Excel format. The XML can have repeating Rows that each have a

1条回答
  •  自闭症患者
    2021-01-28 12:50

    IIUC, you want to transpose the given table - rows to columns, fields to rows. The foilowing stylesheet shows how this can be done. For simplicity, this generates an HTML table - the adjustment for an Excel worksheet should be trivial.

    XSLT 1.0

    
    
    
    
        
        
        
                    
                
                
                        
    Field

    Applied to your example input, the (rendered) result will be:

    0 讨论(0)
提交回复
热议问题