I am currently filing blob object into an MySQL database with the following code:
Dim FS As FileStream = New FileStream(ThePath, FileMode.Open, FileAccess.Read)
Dim BR As BinaryReader = New BinaryReader(FS)
Dim myBlob As MySqlBlob = New MySqlBlob(BR.ReadBytes(Convert.ToInt32(FS.Length)))
MySQLCommand.CommandText = SP.DataFiles_ins(DocFileID, Parser.ParseExtension(ThePath, True))
MySQLCommand.Parameters.Add("TheBlob", myBlob)
MySQLConnection.Open()
Try
Console.WriteLine(String.Concat(MySQLCommand.ExecuteNonQuery(), " rows affected."))
Finally
MySQLConnection.Commit()
MySQLConnection.Close()
BR.Close()
End Try
This routine works great until I try to file a document over 100megs in size. It crashes!!
Is this a limitation of MySQLDirect.Net or am I doing something wrong? If so how should I send large blob objects to the MySQL database?
Thanks
Brad