how to store binary data to MediumBlob Field (VB.net and MysqldriveCS)
i need to store the a filestream to a mediumblob field the problem its that i cant concatenate Filestream type with string
the bellow line shows how i usually make the insert command but itsnt working here cuz filestream object cant be concatenated with string
sql.CommandText = "insert into " & "CBicom" & " values('" & Name & "','" & Value & "');"
Value its the filestream object
so my question its how to make the "insert command" to store the file stream on the field
thx in advance
Last edited by Alphadan; 07-29-2007 at 09:37 AM.
You must read the FileStream into a byte array and then save the bytes to the database: http://support.microsoft.com/kb/317016/
Please post questions to the forums, where others may benefit.
I do not offer free assistance by e-mail. Thank you!
thx phil, for the tip and the link it solved my problem
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL