Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 1 of 1
Thread: ASP + MySQL + Update errors.
12-29-2004, 01:44 AM #1
- Join Date
- Jul 2002
- Thanked 0 Times in 0 Posts
ASP + MySQL + Update errors.
I've changed one of my sites from an Access database to MySQL. Seem to have everything fixed on the site apart from one thing.
I have one page which uploads images into a database that is giving me some problems.
Here is what i am doing to save the image:
File.SaveToDatabase rs("photo_filedata") rs.Update
Public Sub SaveToDatabase(ByRef oField) If LenB(FileData) = 0 Then Exit Sub If IsObject(oField) Then oField.AppendChunk FileData End If End Sub
Query-based update failed because the row to update could not be found.
I've done a good bit of googling and there seems to be a problem with MySQL and the ADO Update method. I would be a lovely solution if I could use SQL Update to add the file data to the database, but there is no nice function in ASP like PHP's stripslashs().
Has anyone got any idea how to get the file into the database with SQL or ADO?