Having submitted a form with a file to upload, I’m having trouble trying to insert it into the longblob field on the image table when using a stored procedure to handle the insert.
Usual basics are set up, multipart/form-data enctype for form, file type for input. When I submit the form and just embedded mysql call in PHP, it uploads the file to the table correctly, just when I pass the details through to the sp, it falls over.
Is there a way to insert the filedata into the blob field via the sp, or is it just going to have to have embedded sql calls in the code?
I agree with Alfabravo, Why not just save the file to a dedicated folder and save a link, or path or just the filename of the file to the database?