Need to export fields containing linebreaks as a CSV from SQL Server

后端 未结 9 596
野的像风
野的像风 2020-12-28 13:49

I\'m running a query from SQL Server Management Studio 2005 that has an HTML file stored as a a string, e.g.:

SELECT html 
FROM table 

Thi

9条回答
  •  死守一世寂寞
    2020-12-28 14:09

    i know this is very old question and has been answered now but this should help as well:

     SELECT html
     From table
     For Xml Auto, Elements, Root('doc') 
    

    it should spit out an xml and then you can import that xml into excel

提交回复
热议问题