Click here to Skip to main content
15,898,538 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Different type (pdf,doc,xls) of files are stored in sql 2005. How to get back into files with the type when they stored.
Posted

1 solution

SQL Server doesn't know anything about file formats. It just stores BLOBs ( Binary Large OBjects ). You read these from the database as an array of bytes. You can save such an array to a file with the right extension using System.IO.File.WriteAllBytes( ... ).

Nick
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900