Hello

I have a question about Firebird .NET Provider. Does it support sequential 
reading of BLOB fields?
I read BLOB like this way:

FbDataReader rd = cmd.ExecuteReader(CommandBehavior.SequentialAccess);
rd.Read();
long bytesDownloaded = 0;
long j=0;
long fileSize = rd.GetBytes(0, 0, null, 0, 0);
byte[] buffer = new byte[BUFFERSIZE];
while (bytesDownloaded < fileSize)
{
    bytesDownloaded += rd.GetBytes(0, j, buffer, 0, buffer.Length);
    //Here update the progress bar and write buffer to a file
    j += buffer.Length;
}

I suppose it should read a BLOB data piece by piece, but it reads the
whole BLOB data and then gets consecutive bytes from it.
It is important for me because I write application that downloads
binary data from a database on a remote server. I would like to update
a progress bar while downloading data, but the program first downloads
all data and then updates the progress bar.

Thank you in advance.

Best regards,
Jacek Salamon 


------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Firebird-net-provider mailing list
Firebird-net-provider@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider

Reply via email to