BCP - Exported files (docx, xlsx & pptx) are corrupted
-
Hi, I am using the below bcp command to export the binary files from the filestream db and all other files are seems to be exported fine (i.e. txt, pdf, rtf, image files & etc) except docx, xlsx & pptx files. I am able to export these files (i.e. docx, xlsx & pptx) but I am getting a warning/error message when opening those files and then it opens the file properly. BCP "SELECT content FROM [dbo].[Contents] WHERE ID=1" queryout "C:\Temp\" -T -S (local) -f C:\Temp\files.fmt I am getting the below message when opening docx, xlsx & pptx files: XLSX - Excel found unreadable content and Do you want to recover the contents of this document? DOCX - The file test.docx cannot be opened bcos there are problems with the content and then Excel found unreadable content and Do you want to recover the contents of this document? Also, I have this in my files.fmt file: 10.0 1 1 SQLBINARY 0 0 "\t" 1 content "" Any help will be much appreciated.