How to include the node XML in my XSLT text output?

后端 未结 2 901
再見小時候
再見小時候 2021-01-13 02:23

I\'m trying to convert an XML file into a flat, pipe-delimited file with XSLT (for bulk-loading into Postgres). I would like the last column in my output to be the actual X

2条回答
  •  隐瞒了意图╮
    2021-01-13 02:58

    I am not sure if this is a recommended solution, but you could try setting the output method to xml, and then just using the xsl:copy-of function.

    So, the following XSLT

     
       
        
       
         
        | 
         
        |  
        
         
        
     
       
      
    

    When applied to your sample XML, generates the following output

    Python Does Everythig|Smith|Python Does EverythigSmith
    Postgres is Neat|Wesson|Postgres is NeatWesson
    

提交回复
热议问题