In a SQL Server 2008 database, I have a table with a column of type varbinary.
Currently, I am using LINQ to SQL to access the database.
I already know that I can delay the loading of the column. However, I wish to consume less memory by not loading all of the bytes from that value.
Ideally, I would like to have a Stream to those bytes.
Is there a way I can attain this? If the answer is yes, how?
views:
323answers:
1
+1
A:
As far as I know this isn't possible using LINQ. You'll have to create your own SqlCommand
object and call ExecuteReader
with the ForwardOnly
property and stream the data out manually.
Adam Robinson
2009-06-18 22:24:45