Working with Binary Large Objects (BLOBs) Using SQL Server and ADO.NET
Applications that deal with Binary Large Objects, or BLOBs, need to evaluate whether to store data inside SQL Server or as a physical file. SQL Server provides the varbinary(MAX) data type to store BLOBs although the older Image data type is still available. The BLOB data can be read in .NET applications by using the SqlDataReader class. The GetBytes() method of SqlDataReader allows you to read chunks of binary data from a column. When writing the binary data back to the database, the SQL server .WRITE clause can be used to write data in chunks. SQL server and ADO.NET together make it easy for you to deal with large binary data such as documents, files, and photos.
Download the Code
You can download the code that accompanies this article here.
About the Author
Page 7 of 7